Linux - NewbieThis 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!
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.
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.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
I have got a problem with my login. I am not able to login through local console or ssh to my machine. In sshd_config file, i have changed the port no. Used DenyUsers, DenyGroups, AllowUsers and blocked the root login. I also used the /etc/hosts.allow to deny some domains,
sshd: .hinet.net deny
I tried to take backup using this command
tar -zcvpf /archive/full-backup-`date '+%d-%B-%Y'`.tar.gz \
--directory / --exclude=mnt --exclude=proc --exclude=var/spool/squid
but it never worked. Now i am not able to login to my machine through ssh or local console. In local console when logging in, it falls back to the login screen saying "Authentication Failure" in a flash.
Please help me get out of this soup. Thanking you all in advance.
Is /archive a mounted network directory or on your filesystem. I think the notion that your filesystem might be full may be correct. You may need to boot up with a live distro, and examine the filesystem that way. You an also double check your /etc/hosts.allow & /etc/hosts.deny files and maybe temporarily undo some of your changes. In the very least, you can read the log file to see why authentication failed.
However, in the future, if you make authentication changes as you have, it is a good idea to be logged in to a local vt and try logging in on a different one. Then if your test fails, you can undo the changes to login again. For changes made remotely, having an active ssh connection and testing making a new connection would be a good idea as well. Don't feel too bad however. I read that locking out all logins is something every system admin has done once. It is very easy to do if you modify the pam configurations.
The AllowUsers entry in /etc/sshd_config takes precedence over DenyUsers, so you just need AllowUsers (and disable root logins) to deny all other regular users & system users.
Thanks for ur comment. I am afraid that if the file system is corrupted then the system will not boot up. How can i check the integrity of my file system and if corrupted how can i restore it, without losing all my other configurations. Can i access the configuration files from rescue mode or single user mode ? Please give me a suggestion.
Thanks for ur comment. Do i need a bootup disk to get into Single User Mode? How can i get in to Single user mode? How can i edit the hosts.allow file from the single User mode? Please give me a suggestion.. Thanking you in advance.
Thanks alot for that comment. Do i need to check my filesystem before editing any conf files? If so how to do it? Also there are only a handful of commands we can use at Single User Mode, is vi available?
vi /etc/hosts.allow, vi /etc/sshd_config
Will these commands run at Single user mode? Can we edit and save the changes using ESC:wq as usual? I only saw pico command at single user mode. If thatz the only way then how to work with that command?