LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Skip login prompt entirely on boot? (https://www.linuxquestions.org/questions/linux-newbie-8/skip-login-prompt-entirely-on-boot-4175656307/)

igrossberg23 06-24-2019 04:04 PM

Skip login prompt entirely on boot?
 
Hi,

I'm working with the server version of Fedora 29 which is command line only. I'm planning to power cycle the whole system and log some information each time using remote power control. The issue I'm having right now is that every time I reboot I get to the login prompt and have to manually enter in username/passwd. Ideally I would like it to completely skip the login prompt and automatically log in to root. I've already removed the password from root so I only type "root [Enter]", but I'd like to skip even that step so I can leave the system power cycling by itself. It feels like there should be an easy way of doing this, but everything I find online assumes access to a GUI, which isn't helpful in my case.

Is there a way to do this?
Thanks!

scasey 06-24-2019 07:09 PM

I don't know if that's possible...and I certainly have an opinion about the wisdom of that, or not having a root password*, but I want to point out that a server need not be logged into at all following a reboot. It should come up, start the necessary (configured) processes and work just fine without anyone logging in to it.

Why do you see entering a login and password at the command line as a problem?



*my opinion: This is a really BAD idea! If the server is publicly accessible, then anyone who connects via ssh and types root <enter> is in your system and can do anything they want. My :twocents:

michaelk 06-24-2019 08:44 PM

It depends. I have some old SBC computers that automatically logged in as root. Granted they were used as standalone devices and only had a serial port for the system console. Puppy linux auto logs in as root.

I don't totally get what the OP is trying to accomplish nor the environment and agree generally it is a bad idea.

You should be able to find how to create a systemd getty service to auto login as root via a quick web search.

frankbell 06-24-2019 09:30 PM

Quote:

Ideally I would like it to completely skip the login prompt and automatically log in to root.
This is not a good practice from a security--or any other--point of view.

ondoho 06-25-2019 02:39 AM

Quote:

Originally Posted by igrossberg23 (Post 6008640)
Ideally I would like it to completely skip the login prompt and automatically log in to root. I've already removed the password from root so I only type "root [Enter]", but I'd like to skip even that step so I can leave the system power cycling by itself.

Ouch, ouch ouch.

And again: empty root password? Ouch, ouch ouch.

You shouldn't be allowed on the Internet. Seriously. You're probably pwned already.

But yes, it's possible:
https://wiki.archlinux.org/index.php...irtual_console

pan64 06-25-2019 04:27 AM

why (do you need that)?

dc.901 06-25-2019 05:47 AM

Quote:

Originally Posted by igrossberg23 (Post 6008640)
Hi,

I'm working with the server version of Fedora 29 which is command line only. I'm planning to power cycle the whole system and log some information each time using remote power control. The issue I'm having right now is that every time I reboot I get to the login prompt and have to manually enter in username/passwd. Ideally I would like it to completely skip the login prompt and automatically log in to root. I've already removed the password from root so I only type "root [Enter]", but I'd like to skip even that step so I can leave the system power cycling by itself. It feels like there should be an easy way of doing this, but everything I find online assumes access to a GUI, which isn't helpful in my case.

Is there a way to do this?
Thanks!

This is like saying; you never want to get the key out and unlock your front door of your home, so take the door out all together.

Why do you want to do this?

rtmistler 06-25-2019 07:43 AM

As pointed out by Ondoho, it appears to be possible, and I haven't followed up much on that reference. Like many others here, it is not a direction I would concentrate on.

Probably more helpful to update and indicate if you have some intentions other than typing convenience.

For instance do you see logging in as a barrier to starting some processes? This is a server, and it's intended to be headless, and act as a host system which various persons can attach too and utilize the processing power of that server. Or it may be hosting services that are accessible by hostname or IP address, such as a home media or file server.

Maybe it's just a system you have the server version installed on, you are using it as a desktop to explore and learn. Who knows, but the advice here from people is not intended to just make arguments about your question. Instead people are familiar with the varieties of things one may do with a server which extend beyond logging in. So, hence the comments and questions about what you are trying to do.

sevendogsbsd 06-25-2019 08:05 AM

This is why people in cybersecurity have jobs...sad to say though.


All times are GMT -5. The time now is 05:02 PM.