FAH autostart in Linux

SatTech

2[H]4U
Joined
Dec 5, 2005
Messages
3,381
Ok, I followed Musky's guide on setting up Linux a while back, and have everything ticking along pretty nicely.

But since I don't know crap about linux, how the heck do you:

1. Have FAH run at start up?
2. Have Linux auto log on to a secured wireless network?

Regrarding #2, at startup I get a password prompt for ring? access. I would really like it to automatically join the network without any input from me.

My job takes me away from home for 4 out of every 6 weeks, and usually have no way of restarting the clients if the machines crash/restart.

Thanks



 
+1 I would also like to know. If the script can apply a tpc overclock as well that would be sweet! ;)
 
1. this can be done using crontab
2. what utilities are you using to connect to wireless? You could setup profiles
 
I need the same info too. I just got my Linux box up last week. It's been fun playing around with a new OS so far.
 
to login without asking password, if you use Ubuntu .. you can go to system --> administration --> users & group .... --> choose your username --> @ login (something) .. click change . At bottom of popup screen .. check (square) box : not ask for password at login ....

To connect to wire/ wireless network, do same steps above , instead of click on CHANGE ( at login ... ), click advance settings. From there you need to check on (square) boxes for wire & wireless.

Hope I remember it correctly .. :D
 
Last edited:
Caveat - you have screen installed - Ubuntu Desktop does by default

To start FAH on boot:
Code:
sudo nano /etc/rc.local
Add to this file:
Code:
cd /home/[user]/fah && sudo -u [user] screen -d -m ./fah6
My user is fah, so my rc.local file ends up like this:
Code:
#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
cd /home/fah/fah && sudo -u fah screen -d -m ./fah6
exit 0
This causes fah to start on boot as your user in a detached screen. To access it, type:
Code:
screen -r
If you control-C to stop it, the screen dies as well. I am sure there is a way to make the screen persist, but I haven't looked into it far enough yet.

I'll have to play around with the wireless question. I know what you are talking about, so hopefully I can duplicate it on a Linux box I have this weekend.
 
Last edited:
what are you using for wireless connection?

The standard one in ubuntu 10.04/10.10 connects automatically to our WPA network w/o my input on our HTPC.....
 
how do i add the tpc overclock script first before running fah?

Add it to rc.local before the fah script. If you need more details, you will have to let me know what this script is. I don't have anything that overclocks, so I am not familiar with what you guys are doing.
 
what are you using for wireless connection?

The standard one in ubuntu 10.04/10.10 connects automatically to our WPA network w/o my input on our HTPC.....

I think you may have to manually add it as a network connection, which will update the keyring. I had the same issue on one of my wireless Ubuntu boxes back when I had them, and it was very annoying. It just wasn't annoying enough to actually try to fix it... :)
 
Maybe thats what i did was a manual network connection......been a while since i set it up..

I think you may have to manually add it as a network connection, which will update the keyring. I had the same issue on one of my wireless Ubuntu boxes back when I had them, and it was very annoying. It just wasn't annoying enough to actually try to fix it... :)
 
1. this can be done using crontab
2. what utilities are you using to connect to wireless? You could setup profiles

No utilities at all. Just installed linux, it downloaded the proper drivers and I picked the adapter for network access.

I only have 1 network cable in this room (if this isn't easily solved, I'll go by a cheap switch) and it's currently hooked up to the SR-2.
 
No utilities at all. Just installed linux, it downloaded the proper drivers and I picked the adapter for network access.

I only have 1 network cable in this room (if this isn't easily solved, I'll go by a cheap switch) and it's currently hooked up to the SR-2.

By utilities they mean what you are using for your wireless ie wiccid, gnome network manager etc.

What distro and version are you running?

From the sounds of it you probably use Gnome network manager and ubuntu. If you store your password in a unsecure keyring then it will not prompt you for your keyring password when you start up and it will just auto connect to the network.
 
By utilities they mean what you are using for your wireless ie wiccid, gnome network manager etc.

What distro and version are you running?

From the sounds of it you probably use Gnome network manager and ubuntu. If you store your password in a unsecure keyring then it will not prompt you for your keyring password when you start up and it will just auto connect to the network.

It is Ubuntu Desktop with the Gnome Network Manager. How do you save the network password to an unsecure keyring?
 
Well, I've been playing with this for a while now, and haven't had any luck getting it to autostart. Anyone have any ideas?

Remember, I'm a linux maroon...
 
Well, I've been playing with this for a while now, and haven't had any luck getting it to autostart. Anyone have any ideas?

Remember, I'm a linux maroon...

Do you mean FAH or the wireless connection?
 
Can you show me your /etc/rc.local file? What I have there worked perfectly in a VM I have. I'll try it again, as soon as I can actually get another VM working...
 
Here's what I've got:

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
cd /home/ben/fah && sudo -u ben screen -m -d ./fah6
exit 0
 
What happens if you run this at a prompt?
Code:
cd /home/ben/fah && sudo -u ben screen -m -d ./fah6

Run this afterwards:
Code:
screen -r
You should see FAH running. Ctrl - A - D will get you out of that screen.
 
One question before all of this - how do you know it is not running? Did you check CPU usage or do screen -r after you started the machine? Your rc.local line looks correct. I just want to make sure we aren't troubleshooting when there isn't a problem.. .:)
 
One question before all of this - how do you know it is not running? Did you check CPU usage or do screen -r after you started the machine? Your rc.local line looks correct. I just want to make sure we aren't troubleshooting when there isn't a problem.. .:)

System usage. The cores never load up.

Ok, I get : "Must run suid root for multiuser support."

When I type in the first line.
 
This is a permission issue, which is strange. Show me the output of
Code:
ls -l ~/fah/fah6
 
Change the order of "-m -d" to "-d -m" like so:

Code:
cd /home/ben/fah && sudo -u ben screen -d -m ./fah6
 
I am still trying to get a VM set up to test, but try what fly said - swap -m -d to -d -m. No idea why that would work, but maybe...
 
I am still trying to get a VM set up to test, but try what fly said - swap -m -d to -d -m. No idea why that would work, but maybe...

That did the trick! Thanks for the help guys. Now I'll play with the wireless log-in issue a little later and report back.
 
I added the start on boot instructions to my installation thread.
 
Got the wireless problems worked out also. I jus deleted the wireless profile and manually added a new one. Bingo, no more password required at boot up.

Yay!
 
Back
Top