Tiny Core Base > Micro Core

bootlocal.sh permission denied

(1/4) > >>

kirin-rex:
I want to add to bootlocal.sh but when I open in editor and try to save, I get permission denied.

I know NOTHING about linux or tiny core or micro-core.  An employee installed micro-core on a bunch of ancient laptops for me because I didn't want to just chuck 'em.  You know?  But he's no longer with us.

So now, where I work, has a hidden wifi ssid, so I googled and found a bootlocal.sh code ... but I'm not sure if "editor" is even what to use.

I've seen screenshots where apparently you can right-click desktop, go to "TOOLS" and select "ADD to BOOTLOCAL" but I don't get that with these laptops.

I googled and found some codes that were supposed to be for permissions:
sudo chown root:staff /opt/bootlocal.sh
sudo chown tc:staff /opt/bootlocal.sh
sudo chown 775 /opt/bootlocal.sh

but was not sure where or how to use them.  I tried the terminal, but to no effect.

Now, I'm not 100% useless.  I've been using computer for over 35 years, since before windows.  I mean, I had a sinclair computer that I played with as a kid ... so I remember old dos commands, etc.

But still, I'm out of my element here.  Can anybody give a clueless newb some advice?
Thanks!

Rich:
Hi kirin-rex

--- Code: ---sudo chown root:staff /opt/bootlocal.sh
sudo chmod 775 /opt/bootlocal.sh
--- End code ---
Editor is what I use when editing files.


--- Quote ---I've seen screenshots where apparently you can right-click desktop, go to "TOOLS" and select "ADD to BOOTLOCAL" but I don't get that with these laptops.
--- End quote ---
Right-click desktop, go to  SystemTools->ControlPanel.  Click the  Backup/Restore  button. The  Backup Maintenance  app will open.

    [EDIT]: Crossed out the incorrect answer I gave.  Rich

kirin-rex:

--- Quote from: Rich on August 19, 2019, 10:03:11 PM ---Hi kirin-rex

--- Code: ---sudo chown root:staff /opt/bootlocal.sh
sudo chmod 775 /opt/bootlocal.sh
--- End code ---
Editor is what I use when editing files.


--- Quote ---I've seen screenshots where apparently you can right-click desktop, go to "TOOLS" and select "ADD to BOOTLOCAL" but I don't get that with these laptops.
--- End quote ---
Right-click desktop, go to  SystemTools->ControlPanel.  Click the  Backup/Restore  button. The  Backup Maintenance  app will open.

--- End quote ---

Thank you for your answer!

For these codes, how do I use them?  Do I add them to bootlocal.sh with editor?  Do I use terminal?  I tried terminal, but it didn't fix the permissions on bootlocal as far as I can tell.

I also looked at backup/restore, and opened the backup maintenance tool, but didn't see options to add something to bootlocal, but am not terribly worried since you mentioned that editor can make those changes.

Rich:
Hi kirin-rex
You enter these commands from a terminal:

--- Code: ---sudo chown root:staff /opt/bootlocal.sh
sudo chmod 775 /opt/bootlocal.sh
--- End code ---

You can check it's correct with the  ls  command:

--- Code: ---tc@box:~$ ls -l /opt/bootlocal.sh
-rwxrwxr-x 1 root staff 132 Feb 28  2012 /opt/bootlocal.sh
tc@box:~$
--- End code ---

kirin-rex:
Thank you very much.  I was able to successfully edit the bootlocal.sh.

However, I'm still having trouble connecting to a hidden wifi.  When I click the wifi icon, of course my workplace wifi doesn't show up.

I looked at this thread:
http://forum.tinycorelinux.net/index.php?topic=19453.0


--- Quote from: jgrulich on January 11, 2016, 01:36:27 PM ---Thank's nitram.
 Your solution may work, but I was not able to open the SSID for evaluation. But finally I've found this solution.
The way is to use the manual config, wifi.sh can't be used at all. The issue was that wpa need to scan ssid's and test them.
I'm using the channel 11 and it takes roughly 12 seconds.
This is my tutorial:

First need to be created the config file, for example /tmp/wifi.cfg.


--- Code: (bash) ---network={
scan_ssid=1
ssid="yourwifiname"
psk="yourwifipassword"
}

--- End code ---

The most important is the scan_ssid=1 parameter which executes the network scan and enables the connection to the hidden networks. This function is not supported by wifi.sh script. The psk may be used in encrypted format generated via wpa_passphrase.

Than need to be created some script for wpa execution and ip querry. This script may be added to bootlocal.sh for automated execution at boot.


--- Code: (bash) ---ifconfig wlan0 up
wpa_supplicant -iwlan0 -c/tmp/wifi.cfg -Dwext -B
udhcpc -i wlan0 -t 10

--- End code ---

The first line may not be necessary at all cases, but some my dongles need it.
The -t 10 parameter is important to safely obtain the ip, because the wpa need pretty long time to scan all the channels as mentioned above. This gives 10 queries with 3 seconds delay, totally 30 second.

This works well and i'ts simple.

--- End quote ---
I found though that putting the newly created wifi.cfg in /tmp/ was a bad idea since that gets cleaned out on reboot, so I put it in /home/.

However, I still don't have it working.  However, I really don't know what I'm doing.  I'm just not knowledgeable enough to know if this is the right thing to do.

Navigation

[0] Message Index

[#] Next page

Go to full version