LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-07-2005, 05:18 PM   #1
mnemonic
LQ Newbie
 
Registered: Jun 2002
Distribution: Gentoo
Posts: 8

Rep: Reputation: 0
Making dhcpcd and X run on login


How do I make it so that after logging in as a normal user, "startx" and "dhcpcd eth0" are automatically executed? Putting them in .bashrc isn't a nice solution because those commands are executed with every new shell. Also I'd rather not use a graphical login because that lengthens my startup time

I've already changed the necessary dhcpcd permissions so that a normal user can use dhcp.
 
Old 08-07-2005, 06:17 PM   #2
misunderstruck
LQ Newbie
 
Registered: Jan 2005
Location: Brooklyn, NY
Distribution: Gentoo; Fedora Core 3
Posts: 28

Rep: Reputation: 15
The following is based on the assumption that you're using Gentoo, as mentioned in your user id.

Is net.eth0 in your default runlevel? You can try
Code:
# rc-update add net.eth0 default
This will add net.eth0 to your default runlevel if it's not there and will do nothing if it is already there (except tell you that it is there). Of course, this will start the networking on boot rather than after logging in as a normal user, which I realize is not exactly what you were asking for.

Also, make sure that the entry for eth0 in /etc/conf.d/net looks like config_eth0=("dhcp") and that net.eth0 is symlinked to net.lo (to check, use:
Code:
ls -l /etc/init.d/ | grep net
). That has worked without much problem for me. And if I lose the network connection I just use the following to bring it back up:
Code:
# /etc/init.d/net.eth0 restart
I imagine to have startx executed you would have to be logged in automatically as well. Check out the following thread from Gentoo's forums for suggestions:
http://forums.gentoo.org/viewtopic-t...tic+login.html
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Slack 10: Why must I run dhcpcd manually? IamI Slackware 5 11-23-2005 08:26 AM
Have to run dhcpcd every start up. Nz_Boy_2004 Linux - Distributions 3 05-21-2005 08:28 PM
making a command run after boot phillips321 Linux - Software 1 04-19-2005 09:11 PM
Making Another Run at Linux! saturninus Linux - Newbie 6 09-27-2004 09:49 AM
dhcpcd: making life hard! e1000 Slackware 4 12-06-2003 01:33 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 11:07 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration