Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
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.
|
 |
10-03-2007, 07:32 AM
|
#1
|
LQ Newbie
Registered: Oct 2007
Posts: 4
Rep:
|
Single User mode
Hello,
Am I right that Single user mode uses the least amount of system resources because it is in text and no extra processes are running.
In Ubuntu, may I know how do I automatically enable SSH Server when I use "init 1" to get into Single user mode?
Thanks.
|
|
|
10-03-2007, 07:35 AM
|
#2
|
Moderator
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417
|
you can't... "single user mode" does not support networking at any level. if you are looking to free up resources, you could personalise an alternative runlevel, e.g. 4 to suit your needs if you want multiple "modes" of run.
|
|
|
10-03-2007, 08:03 AM
|
#3
|
LQ Newbie
Registered: Oct 2007
Posts: 4
Original Poster
Rep:
|
Where and how do I personalize an alternative runlevel in Ubuntu? Thanks.
Quote:
Originally Posted by acid_kewpie
you can't... "single user mode" does not support networking at any level. if you are looking to free up resources, you could personalise an alternative runlevel, e.g. 4 to suit your needs if you want multiple "modes" of run.
|
|
|
|
10-03-2007, 10:19 AM
|
#4
|
Senior Member
Registered: Jan 2003
Location: Illinois (SW Chicago 'burbs)
Distribution: openSUSE, Raspbian, Slackware. Previous: MacOS, Red Hat, Coherent, Consensys SVR4.2, Tru64, Solaris
Posts: 2,852
|
Quote:
Originally Posted by isolvesystems
In Ubuntu, may I know how do I automatically enable SSH Server when I use "init 1" to get into Single user mode?
|
Single-user mode is normally used for system maintenance tasks such as repairing filesystems and the like so I can't imagine why you'd want someone to be able to connect while you're in the middle of that, but if you really wanted to, you could switch to single-user and manually run the startup scripts until you had a configuration that had basic networking up and running. I'd guess that you'd want to go into /etc/rc.d/rc3.d (on SUSE, anyway) and run all the "K" scripts and then run the "S" scripts in order until you got networking started. (On SUSE this would be S05network.) You're definitely not going to be in single-user mode any more and you won't be quite up to level 3. At that point you could try starting the sshd daemon.
Another thing you might need to do is to make sure that /dev/pts is mounted. It's been a while but seem to recall that that needed to be mounted in order for remote logins to work. (I'd test that but I'm in the middle of testing something and don't want to risk messing it up.  )
Good luck...
|
|
|
10-03-2007, 03:58 PM
|
#5
|
Member
Registered: Jun 2006
Location: Belarus
Distribution: Debian GNU/Linux testing/unstable
Posts: 471
Rep:
|
There is a bad idea to modify single-user mode.
Better modify any other runlevel (e.g. second) for your needs. You can do this by switching to /etc/rc2.d directory and placing the start links to /etc/init.d/networking, /etc/init.d/ssh and others needed by you daemons; and the stop links to all daemons you don't need.
|
|
|
10-03-2007, 08:05 PM
|
#6
|
LQ Guru
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.x
Posts: 18,442
|
Sounds like you should use runlevel 3 (in /etc/inittab) and then disable any daemons/services you don't need.
|
|
|
All times are GMT -5. The time now is 02:37 PM.
|
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
|
|