Linux - SoftwareThis 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.
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.
While saving a file in vi I managed to overwrite my /etc/inittab file with something certainly not suited for being there. By adding single as a kernel argument in grub I am able to get into single-user mode and in that way type in a functioning inittab. In order to do so, however, i will need someone -- preferably running fedora core 3 -- to post their /etc/inittab file.
I use Fedora 3, the only thing you may want to modify is I boot to runlevel 3, no graphics until I give the startx command.
# inittab This file describes how the INIT process should set up
# the system in a certain run-level.
# Author: Miquel van Smoorenburg, <email@example.com>
# Modified for RHS Linux by Marc Ewing and Donnie Barnes
# Default runlevel. The runlevels used by RHS are:
# 0 - halt (Do NOT set initdefault to this)
# 1 - Single user mode
# 2 - Multiuser, without NFS (The same as 3, if you do not have networking)
# 3 - Full multiuser mode
# 4 - unused
# 5 - X11
# 6 - reboot (Do NOT set initdefault to this)
# System initialization.
# Trap CTRL-ALT-DELETE
ca::ctrlaltdel:/sbin/shutdown -t3 -r now
# When our UPS tells us power has failed, assume we have a few minutes
# of power left. Schedule a shutdown for 2 minutes from now.
# This does, of course, assume you have powerd installed and your
# UPS connected and working correctly.
pf::powerfail:/sbin/shutdown -f -h +2 "Power Failure; System Shutting Down"
# If power was restored before the shutdown kicked in, cancel it.
pr:12345:powerokwait:/sbin/shutdown -c "Power Restored; Shutdown Cancelled"
# Run gettys in standard runlevels
# Run xdm in runlevel 5
I were done typing in my inittab and when saving it didn't work like it should. After quitting vi I tried to delete the inittab file in order to retry making a new one. rm exited with the error "cannot remove "inittab" read only filesystem".
without the single in grub my system won't boot. ( as my inittab is rubbish)
You're right, I misunderstood you. I haven't played in single user mode, but that sounds like a permissions issue. You can maybe (outside of vi) do a
mv /etc/inittab /etc/inittab.old
Maybe become su before opening the file to edit? Not sure of how permissions work in single user mode. You could accomplish this easier I'd suspect with knoppix or any live CD, or the recovery disk from Fedora.
moving (or rather renameing) the file failes with the same error as removing. But using a live CD sounds like a good idea. I will test it right away as i have one handy. I have tried using su, but it didn't make any difference. It seems like the fs is mounted read only.
Yeah, a live CD will (after changing a few things) allow you to modify files on the hard disk. They usually mount read only, but you can change that to allow writing. Then you can copy my inittab and paste it in, getting everything done at once, in about 30 seconds.
I need to use windows in order to get this fil from the internet since i do not hav networking in my live-eval. I can't make it work, and believe it is because windows stores the file in another format (vi reports [dos] when viewing the file.)
Do you know any workaround for this? / Can you post the file as a file instead of as text so that i want have to edit it in windows?