summaryrefslogtreecommitdiffstats
path: root/loader/init.c
Commit message (Collapse)AuthorAgeFilesLines
* Remove init.[ch].Chris Lumens2011-04-121-160/+0
| | | | | There's no code left in these files that I want to move anywhere, so the remaining parts can go.
* Move debugging features into loader.c.Chris Lumens2011-04-121-68/+0
|
* Move serial console handling code out into its own file.Chris Lumens2011-04-121-206/+2
|
* Remove all the custom shutdown/reboot/halt code in loader and init.Chris Lumens2011-04-121-43/+0
| | | | | These decisions will now be made in anaconda proper. There's no need to involve three separate processes in the discussion.
* Move syslog starting into loader.Chris Lumens2011-04-121-122/+0
|
* loader doesn't support arguments except from /proc/cmdline.Chris Lumens2011-04-121-14/+0
| | | | | | This gets rid of all the argument parsing code in init, loader support for reading args in some sort of test mode, and hopefully the last of the bogl support.
* Remove the duplicate backtrace setup code in init.c.Chris Lumens2011-04-121-55/+0
|
* Remove from init.c/loader.c things that systemd does for us.Chris Lumens2011-04-121-267/+1
| | | | | | | * We don't need to populate /dev. * We don't need to mount filesystems. * We don't need to start dbus or udevd. * We don't need to start a shell in multiple places.
* shutdown: kill processes in the anaconda process group.Ales Kozumplik2011-03-231-2/+0
| | | | | | | | Previously killall5 omitted the init's session (which includes the anaconda process group) and anaconda and everything spawned from there (including the vnc server) survived both the killall5 calls. Related: rhbz#679397
* Don't fatal_error if required mounts are already mountedWill Woods2011-03-171-5/+10
| | | | | | | Change loader/init.c so it doesn't bother checking the return value of mount(). Instead it just checks to see if the mount functions as expected - for example, after mounting /proc it checks to see if /proc/cmdline exists.
* Don't fatal_error if remounting root read-write failsWill Woods2011-03-171-3/+1
| | | | | | | As long as we can write to a few places (e.g. /etc, /var, /tmp) it's OK if the root filesystem is readonly. Remove the fatal error if the mount fails. Also clean up the mount call a bit - MS_MGC_VAL hasn't been required since kernel 2.4...
* Create the virtio-ports on time.Ales Kozumplik2011-03-091-3/+4
| | | | | | | | This is done by a narrowly aimed 'udev trigger' call that shouldn't retrigger anything else. No related modules need to be loaded manually now, they're builtin. Resolves: rhbz#672527
* devt.h is no longer useful, remove it.Chris Lumens2011-03-031-1/+0
|
* remove unused variablesMichal Schmidt2011-02-031-16/+12
| | | | | | | | | | | There were two kinds of unused but set variables: - the really pointless ones - the ones whose only purpose was to silence the warnings about ignoring the return values from functions declared with __attribute__((__warn_unused_result__)) Since gcc 4.5 the warnings can be disabled using -Wno-unused-result, so the variables are no longer necessary. Then -Wno-unused-but-set-variable is an overkill, so drop it.
* Correct paths of things started by loader/init that have moved.Chris Lumens2010-10-151-3/+3
|
* Dynamically initialize MALLOC_PERTURB_ when loader starts.Peter Jones2010-09-241-0/+63
| | | | | | | | | Seriously overengineer the initialization of the env variables we pass to loader so that we can set MALLOC_PERTURB_ to a random number. Is this worth it - who can say? You could be listening to the score of "The Magnificent Seven" right now, but you're not.
* Fix setting of $HOMEPeter Jones2010-09-241-2/+1
| | | | | Setting HOME to /root didn't work right because I invented two mechanisms to do the same thing. Get rid of one of them.
* logging: fix logic in getSyslog().Ales Kozumplik2010-08-091-46/+28
| | | | | | Not working right since 88958d9d84f48cfa0f3ca7ff94326b49c252ebe1. Related: rhbz#576439
* Use readvars_parse_file in loader/init.cDavid Cantrell2010-07-261-106/+64
|
* Check return value of chdir()David Cantrell2010-07-261-3/+6
| | | | | If chdir() does not return 0, display an error of some sort and don't do what we were about to do.
* Remove USE_MINILIBC cruft from loader/init.cDavid Cantrell2010-07-261-9/+0
|
* logging: autodetect the virtio-serial port.Ales Kozumplik2010-07-261-24/+47
| | | | | | | | | | | Discussed with jlaska and amit. Removes the virtiolog= command line parameter again, istead we will always look for /dev/virtio-ports/org.fedoraproject.anaconda.log.0 and forward logs to it if it exists. In theory, with some cooperation from the libvirt team, this could ensure every F14 installation has remote logging set up, ready to be picked on the host. Related: rhbz#576439
* Make the shell in tty2 and ssh all go to /root like on a real system.Peter Jones2010-07-221-0/+2
| | | | | | | ssh was already droping you there (though I'm not entirely sure where the directory is coming from in that case), and you'd not have .bash_history and .profile and .gdbinit. So now everything uses /root , and you get the stuff you might expect.
* logging: support logging through virtio-serial (#576439).Ales Kozumplik2010-07-201-9/+46
|
* Improve parsing and pass the devel flag to loader through the command lineMartin Sivak2010-07-151-3/+33
| | | | This gets rid of ugly checking for this in /proc/cmdline in loader and init checks if devel is actually a single word to avoid conflicts
* When in devel mode, do not catch tracebacks, we want the core fileMartin Sivak2010-07-151-1/+10
| | | | - also make sure the terminal is in usable state when back in init
* Add better debugging capabilities to loaderMartin Sivak2010-07-151-7/+47
| | | | | - when development ('devel' argument) mode is requested, init enables core dumping and starts shell in the case of unexpected exit
* Wait on all pids, not just udevd's. (#540923)Peter Jones2010-04-131-3/+3
| | | | | | If we wait only on udevd's pid, it means we've got zombie processes hanging out. So instead, wait on all pids, and then only do the udevd stuff if we actually see udevd exit.
* init: switch back to tty1 after the installer finishes. (#577380)Ales Kozumplik2010-04-121-1/+3
|
* sparc64 is a lib64 archDennis Gilmore2010-03-151-1/+1
| | | | make sure sparc64 has lib64 paths set that same as other 64 bit arches that use lib64
* Improve reboot modes in init.c and shutdown.c.Ales Kozumplik2010-02-101-4/+4
| | | | | | | | Stop the kernel correctly on HALT (so that we dont see 'kernel panic, they killed init' on i386 and on s390 one gets easy access to manual IPL). Introduce a new reboot method that does allow us to see the backtrace and doesn't scroll the screen up with useless unmount info.
* init, fixes a bug in getSyslog() causing a SEGVAles Kozumplik2010-01-251-1/+1
| | | | The error could be triggered, e.g. by appending 'stage2=hd:label="fedora"' to the boot line.
* Prevent init from telling us its story if the shutdown was planned.Ales Kozumplik2010-01-221-0/+1
| | | | | | | | dcantrell's recent change to the shutdown mechanism exposed a situation when shutdown is correctly handled but the init's exit handler still gets called and dumps its callstack, that's not desirable because (in case of an exception in python code for example) part of the useful information on the screen is scrolled out of view.
* Introduces rsylogd to anaconda (part of #524980)Ales Kozumplik2010-01-201-156/+81
| | | | | | | A proper syslog daemon allows for remote logging that includes installed system's syslog. Removes the init.c code that simulated syslog activity until now.
* Fix compile problem from 65a3c05.Ales Kozumplik2010-01-201-1/+0
|
* Changed the architecture check from __ppc64__ to __powerpc64__ (#555669)Martin Gracik2010-01-151-1/+1
| | | | | | Wrong check for the architecture resulted in having no lib64 directories in LD_LIBRARY_PATH, and that's why anaconda couldn't find the libudev library.
* stage1 (init): Make /tmp tmpfs large enough to hold install.img (#540146)Hans de Goede2009-12-041-1/+1
| | | | | | | | | | Be default mount makes tmpfs mounts 1/2 RAM size, on 256MB machines, where part of the RAM is taken up by a shared framebuffer, this results in a /tmp which is to small to hold install.img, resulting in install failure when trying to do for example a network installation. This patch fixes this by specifying a size for /tmp, it uses 250MB which should be plenty for now and the forseeable future.
* Remove test mode from the loader, too.Chris Lumens2009-12-031-97/+64
| | | | | All previous comments about test mode being untested apply to loader, but doubly so.
* Get rid of dead code, and fix gettimespecofday's math.Peter Jones2009-11-061-6/+0
| | | | | We've got a lot of dead code here. This removes a bunch of it. Also, it fixes gettimespecofday's math to yield the correct result.
* Don't exec without forking first when calling udevadm.Peter Jones2009-11-051-7/+32
| | | | | | Since we don't want init to exit when we call udevadm, fork first. But before we do that, may as well wait for our forked udevd to exit, so there's some chance it's listening for connections.
* If init or loader exit unexpectedly, traceback.Peter Jones2009-11-051-7/+71
| | | | | | | | | | | Currently if init exits unexpectedly, we get "Kernel panic - not syncing: Attempted to kill init!" and then a useless kernel traceback (hey, it went through do_exit()!, who'd'a thunk?) but nothing meaningful about what went wrong in init. This patch attempts to rectify this situation by adding the traceback handler from loader to init, as well as triggering it (in both loader and init) if we exit without going through a path we've specifically marked, by using doExit() instead of exit(3) or _exit(2), as not needing a traceback.
* Fix the vim magic in this file to work.Peter Jones2009-11-051-1/+2
| | | | | | This fixes the vim magic to be something it'll actually do something with. I probably got it wrong the first time, but hey, better usable than not.
* Re-enable running udevadm.Chris Lumens2009-10-261-2/+0
| | | | This snuck in as part of another commit when it shouldn't have.
* Support upgrading when the language isn't in lang-table (#528317).Chris Lumens2009-10-131-0/+2
|
* Don't run 70-anaconda.rules on an installed system (#527781).Chris Lumens2009-10-131-0/+2
| | | | | | | | The livecd includes anaconda, for obvious reasons. However this means that 70-anaconda.rules will be installed on the finished system and running our rules has some unusual side effects. While we slowly push our udev rules changes into upstream packages, this should make them a no-op on the installed system.
* Stop /lib/udev/rules.d/65-md-incremental.rules from messing with mdraid setsHans de Goede2009-09-301-0/+5
| | | | | | | | | | Touch /dev/.in_sysinit, as that stops /lib/udev/rules.d/65-md-incremental.rules from messing with mdraid sets. This patch adds the touching twice, once to our own init, for when running as standalone installer, and once in python for when running from a livecd, to stop the udev trigger "block" we do will cause /lib/udev/rules.d/65-md-incremental.rules to trigger in the livecd case.
* setup termcap for sparcDennis Gilmore2009-08-181-1/+9
|
* Fix ctrl-alt-deleter behavior /before/ end of install.Peter Jones2009-08-041-0/+1
| | | | | | The new reboot code didn't take into account the fact that there's a different sigint handler while anaconda is running vs when we're done installing. This patch fixes that bad assumption.
* Rework shutDown() to better accomidate "nokill" better.Peter Jones2009-07-301-14/+13
| | | | | | Rework shutDown() so that we don't do unmounts until we're going to reboot or power off the machine. Also some minor cleanups like taking out all the negative-phrasing of "noKill" in the code itself.
* Remove umask temporarily so device permissions are correct (#383531, wmealing).Chris Lumens2009-06-051-0/+8
|