Linux - Laptop and Netbook Having a problem installing or configuring Linux on your laptop? Need help running Linux on your netbook? This forum is for you. This forum is for any topics relating to Linux and either traditional laptops or netbooks (such as the Asus EEE PC, Everex CloudBook or MSI Wind). |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
08-01-2005, 08:45 PM
|
#1
|
LQ Newbie
Registered: Jul 2005
Location: PA, USA
Distribution: Ubuntu v5.04 Hoary Hedgehog
Posts: 27
Rep:
|
Performing an action every reboot
The touchpad on my Compaq Presario R3210US does not work on boot up unless I issue the following commands: rmmod psmouse, modprobe psmouse. Then it works immediately.
I've tried adding these commands to /etc/X11/xinit/xserverrc and it doesn't work on startup still unless I manually issue the commands. Where else should I look to add these to get my touchpad working all the time? I'm using Ubuntu 5.04.
Thanks in advance.
|
|
|
08-01-2005, 11:26 PM
|
#2
|
Member
Registered: Mar 2005
Location: Chicago
Distribution: Gentoo AMD64
Posts: 365
Rep:
|
You could put those commands at the end of any executable file in the /etc/init.d directory or make your own and chmod +x it.
|
|
|
08-02-2005, 05:05 PM
|
#3
|
LQ Newbie
Registered: Jul 2005
Location: PA, USA
Distribution: Ubuntu v5.04 Hoary Hedgehog
Posts: 27
Original Poster
Rep:
|
In my init.d directory, I made a file called mouseinit and put the following code inside it:
Code:
rmmod psmouse
modprobe psmouse
I then did a chmod +x on the file, but the touchpad still doesn't work unless I do a rmmod psmouse and modprobe psmouse manually.
Any other ideas?
|
|
|
08-02-2005, 05:11 PM
|
#4
|
Member
Registered: Mar 2005
Location: Chicago
Distribution: Gentoo AMD64
Posts: 365
Rep:
|
Maybe the file has to start with "rc.", try putting those commands in any other script.
|
|
|
08-02-2005, 05:14 PM
|
#5
|
LQ Newbie
Registered: Jul 2005
Location: PA, USA
Distribution: Ubuntu v5.04 Hoary Hedgehog
Posts: 27
Original Poster
Rep:
|
Tried renaming the file to rc.mouseinit - no go. Grr.
All the scripts in this directory in Ubuntu aren't in a rc.name format. I'm thinking maybe Ubuntu loads stuff a bit differently than other distros? I know in Slackware I had an easy time loading commands on bootup by adding lines to my rc.local file.
Last edited by Zaulden; 08-02-2005 at 05:17 PM.
|
|
|
08-02-2005, 06:44 PM
|
#6
|
Member
Registered: Feb 2003
Location: Parker, CO USA
Distribution: CentOS primarily but I multi-boot my laptop to Ubuntu or Fedora Core 10 as needed
Posts: 48
Rep:
|
Traditionally stuff like this should just be added to /etc/rc.d/rc.local. For my HP Pavilion the magic to making the touchpad (Synaptics) work is to execute the following command when the system boots:
echo -n "reconnect" > /sys/bus/serio/devices/serio0/drvctl
No reason you can't add your rmmod and modprobe commands instead. rc.local gets executed *after* all other initialization scripts (the stuff in /etc/init.d). This should still be prior to X if you boot in graphical mode.
|
|
|
08-03-2005, 08:14 AM
|
#7
|
LQ Newbie
Registered: Jul 2005
Location: PA, USA
Distribution: Ubuntu v5.04 Hoary Hedgehog
Posts: 27
Original Poster
Rep:
|
In my Ubuntu install, I don't have a /etc/rc.d/ directory.
Instead, I have a rc0.d, rc1.d, rc2.d, rc3.d, rc4.d, rc5.d, rc6.d, and rcS.d. Also, in all of these directories, there is no rc.local file.
Could anyone be of any further assistance?
|
|
|
08-03-2005, 10:31 AM
|
#8
|
Member
Registered: Apr 2005
Location: Canada
Distribution: Slackware
Posts: 496
Rep:
|
At worst you could try appending it to your actual runlevel script (so it starts as part of the normal runlevel X process).
|
|
|
08-03-2005, 10:39 AM
|
#9
|
LQ Newbie
Registered: Jul 2005
Location: PA, USA
Distribution: Ubuntu v5.04 Hoary Hedgehog
Posts: 27
Original Poster
Rep:
|
I actually found out from a previous thread how to do this just now...
http://www.linuxquestions.org/questi...hreadid=346690
I followed the first technique, which involved making my own rc.local file, but it seems there is also a bootmisc.sh which I can append to with commands, but that file seems pretty full of nested ifs, so I'm not sure where to put extra commands.
Either way, I finally got it working, so if anyone else ever has this problem with Ubuntu... check out that thread.
|
|
|
08-03-2005, 05:28 PM
|
#10
|
LQ Newbie
Registered: Jul 2005
Distribution: Ubuntu "Dapper" 6.06 LTS
Posts: 18
Rep:
|
I don't mean to take over this thread but as it seems Zaulden has fixed his problem...I have another question:
I thought it might work to put the commands into a cron job (system wide /etc/crontab or personal ~/crontab) with the "@reboot" tag like so (See "man 5 crontab" for the "@reboot" tag)
But I wasn't sure how soon after reboot the job would run, so I tested it:
Code:
user@localhost:~$ cat /etc/crontab
[...]
@reboot root /usr/bin/uptime
user@localhost:~$ cat ~/crontab
@reboot /usr/bin/uptime
user@localhost:~$ crontab -u user ~/crontab
user@localhost:~$ shutdown -h 2 # 2 minutes to let the system wide crontab to load
However neither one worked!!!
Anyone know how i should have done this ???
|
|
|
All times are GMT -5. The time now is 12:12 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|