Commit graph

47 commits

Author SHA1 Message Date
Eelco Dolstra 15d44498f9 * Add a ‘size’ option to ‘swapDevices’ to create swapfiles on the fly.
svn path=/nixos/trunk/; revision=34478
2012-06-12 13:41:51 +00:00
Rob Vermaas 53af6f5668 Execute mount-all task on config-changed event to make sure it is performed before other upstart jobs are started on activating the new configuration.
svn path=/nixos/trunk/; revision=34201
2012-05-21 21:26:45 +00:00
Eelco Dolstra 6a6eec0f53 * Add a filesystem option ‘autoFormat’ to automatically do a format if
the device has no filesystem yet.  Useful in Charon deployments.
  The check for an uninitialised filesystem is kind of shaky now.

svn path=/nixos/trunk/; revision=34133
2012-05-16 00:03:44 +00:00
Eelco Dolstra 67d5f2b444 * Require fileSystems to be set.
svn path=/nixos/trunk/; revision=34080
2012-05-14 01:33:11 +00:00
Eelco Dolstra f2fd48e131 * Fix the "autocreate" option.
svn path=/nixos/trunk/; revision=33750
2012-04-11 21:21:00 +00:00
Eelco Dolstra 2a135eb4d4 * Remove the ‘services.nfs.client.enable’ flag; use
‘boot.supportedFilesystems = [ "nfs" ]’ if needed.

svn path=/nixos/trunk/; revision=33356
2012-03-22 12:24:23 +00:00
Lluís Batlle i Rossell 20edb255bd Adding idmapd, for NFSv4.
Patch by Rickard Nilsson.

This may fix rpc.statd start.


svn path=/nixos/trunk/; revision=33330
2012-03-21 11:58:06 +00:00
Eelco Dolstra 4acc48fc2d * Mark tasks such as mount-failed as not to be restarted.
svn path=/nixos/trunk/; revision=33237
2012-03-18 18:04:49 +00:00
Eelco Dolstra 362d1389d3 * mountall: make the "console output" Upstart stanza do its work. We
were redirecting output to /var/log/upstart/<job>, so it didn't work
  properly.
* mountall-ip-up: send the USR1 signal to the mountall process by
  looking up its PID, rather than doing "pkill -USR1 mountall".  This
  prevents a very subtle race condition where USR1 is delivered to a
  child process of mountall (such as fsck), if pkill sees the child
  just before its execve().  There is actually still a race condition
  because mountall installs its USR1 handler *after* daemonising, so
  mountall-ip-up could accidentally kill mountall.  Should report this
  to upstream.

svn path=/nixos/trunk/; revision=33236
2012-03-18 17:48:19 +00:00
Eelco Dolstra 5a98d6d514 * mountall: Don't start the emergency shell if the X server is
running.  The user won't see it, and the "console owner" stanza
  breaks VT switching and causes the X server to go to 100% CPU time.

svn path=/nixos/trunk/; revision=33221
2012-03-18 01:44:20 +00:00
Eelco Dolstra ee6c9bb998 * Provide two utility functions in Upstart jobs: "ensure JOBNAME"
starts the given job and waits until it's running; "stop_check"
  checks that the current job hasn't been asked to stop.

svn path=/nixos/trunk/; revision=33214
2012-03-17 19:12:33 +00:00
Eelco Dolstra 67a90c6d6f * Renamed services.nfsKernel to services.nfs. Unfortunately
rename.nix doesn't allow renaming sets of options...
* Renamed nfs-kernel.nix to nfsd.nix
* Move NFS client stuff from nfsd.nix to filesystems/nfs.nix.

svn path=/nixos/trunk/; revision=33174
2012-03-16 20:41:49 +00:00
Eelco Dolstra e963fe2b2c * Forgot to commit.
svn path=/nixos/trunk/; revision=33173
2012-03-16 20:23:45 +00:00
Eelco Dolstra 6b2dfbda00 * Make the mountall job depend on /etc/fstab so that it gets restarted
when fstab changes.

svn path=/nixos/trunk/; revision=33108
2012-03-15 13:54:23 +00:00
Eelco Dolstra 03ebb883d1 * Modularize filesystem support. Filesystems such as btrfs and
reiserfs now have separate modules that are conditional on
  boot.supportedFilesystems and boot.initrd.supportedFilesystems.
  By default, these include the filesystems specified in the fsType
  attribute in fileSystems.  Ext2/3/4 support is currently
  unconditional.

  Also unbreak the installer test (http://hydra.nixos.org/build/2272302). 

svn path=/nixos/trunk/; revision=32954
2012-03-09 14:37:58 +00:00
Lluís Batlle i Rossell 9d1b72a6c7 Making nixos fileSystems aware of fsType "reiserfs" and "btrfs", regarding
modules, tools, intrd pieces, ...

That's only useful if the user specifies fsType, though.


svn path=/nixos/trunk/; revision=32912
2012-03-08 21:07:25 +00:00
Peter Simons b5dc3d520e optionally run "btrfs device scan" during mountall.
As reported by Bryce L Nordgren.

Multi-disk btrfs filesystems need to get assembled first before they become mountable.
Enable this by explicitly assigning fsType = "btrfs" in the filesystems list in configuration.nix

svn path=/nixos/trunk/; revision=32682
2012-02-28 17:43:43 +00:00
Eelco Dolstra 52e6088c88 * utillinuxng -> utillinux.
svn path=/nixos/trunk/; revision=30858
2011-12-12 19:02:37 +00:00
Eelco Dolstra 021409b21f * Declaring fileSystems as "loa" (list or attribute set) is bad because it can
cause the filesystems to be reordered.  During stage 1, the ordering of
  filesystems is sensitive.  (In stage 2, mountall ensures that filesystems
  are mounted in the right order.)

svn path=/nixos/trunk/; revision=30046
2011-10-26 19:37:47 +00:00
Peter Simons eb6e1310b8 strip trailing whitespace; no functional change
svn path=/nixos/trunk/; revision=29285
2011-09-14 18:20:50 +00:00
Eelco Dolstra bd5ca54584 * Add fsck.vfat etc. to the default install. Useful for USB sticks
and stuff like that.

svn path=/nixos/trunk/; revision=28934
2011-08-30 18:25:54 +00:00
Nicolas Pierron ef63ea98f4 Experiment with dual option types (list & attribute sets).
svn path=/nixos/trunk/; revision=27978
2011-07-27 20:55:35 +00:00
Eelco Dolstra b756a1ee81 * Added an option to disable fsck on particular filesystems.
svn path=/nixos/trunk/; revision=23744
2010-09-13 11:46:35 +00:00
Eelco Dolstra dc0db647a9 * Remove a debug line that should not have been committed.
svn path=/nixos/trunk/; revision=22566
2010-07-12 16:40:02 +00:00
Eelco Dolstra 14ddf8e096 * On an `ip-up' event, notify mountall so that it retries mounting
remote filesystems.

svn path=/nixos/trunk/; revision=22564
2010-07-12 16:07:26 +00:00
Eelco Dolstra 9ac60a3aa3 * Merge the ‘nfs-kernel-sm-notify’ task into the post-start script of
the ‘nfs-kernel-statd’ task.
* Work around an apparent bug in Upstart: the ‘mountall’ task cannot
  be restarted because of the ‘starting mountall’ condition in the
  statd task.  So instead make ‘mountall’ depend on ‘started
  nfs-kernel-statd’.

svn path=/nixos/trunk/; revision=22508
2010-07-07 12:11:29 +00:00
Eelco Dolstra 4225181fa1 * Ensure that the ‘mount-failed’ and ‘emergency-shell’ tasks don't get
started by ‘switch-to-configuration.sh’.

svn path=/nixos/branches/boot-order/; revision=22473
2010-07-05 09:28:22 +00:00
Eelco Dolstra a9e8bf6491 * nfsd: run rpc.nfsd from the pre-start script since it's not actually
a daemon (it just starts some kernel threads).  In the post-stop
  script, stop the kernel threads.
* exportfs: fix the createMountPoints option.
* Mount the nfsd filesystem on /proc/fs/nfsd because mountd prefers
  this.

svn path=/nixos/branches/boot-order/; revision=22187
2010-06-08 16:01:31 +00:00
Eelco Dolstra 6290788247 * If mountall fails to mount all filesystems, start an emergency shell
to allow the user to fix or ignore the problem.

svn path=/nixos/branches/boot-order/; revision=22165
2010-06-07 12:15:55 +00:00
Eelco Dolstra 5702557a65 * Put e2fsprogs etc. in mountall's $PATH so that fsck works.
svn path=/nixos/branches/boot-order/; revision=22151
2010-06-04 15:35:32 +00:00
Eelco Dolstra dbadf6e9c2 * Use mountall to mount all filesystems and activate all swap devices
during boot.  Mountall ensures that these are done in the right
  order.  It's informed by udev about devices becoming available.  It
  emits some Upstart events upon reaching certain states, in
  particular ‘local-filesystems’ after all local filesystems have been
  mounted successfully, ‘remote-filesystems’ after all network
  filesystems have been mounted, and ‘filesystem’ (sic) when all
  filesystems have been mounted.

  Currently, if a filesystem fails to mount or doesn't exist, then the
  mingettys won't start and the boot will appear to hang.  This is
  because mountall doesn't emit an event for failing filesystems and
  waits indefinitely for the filesystems to become available.

* The ‘filesystems’ and ‘swap’ Upstart jobs are gone.  (Support for
  encrypted swap devices is temporarily gone.)
  
* Generate a proper /etc/fstab from the ‘fileSystems’ and
  ‘swapDevices’ options.

svn path=/nixos/branches/boot-order/; revision=22148
2010-06-04 14:22:11 +00:00
Eelco Dolstra 7f41d2bb86 svn path=/nixos/trunk/; revision=22126 2010-06-03 14:32:23 +00:00
Eelco Dolstra cf06d2b9cf * Don't start the filesystems task on a startup event. It's pointless
to do so until udev has created device nodes.

svn path=/nixos/trunk/; revision=19332
2010-01-10 18:23:13 +00:00
Eelco Dolstra b86e8208d5 * Doh! The mount options weren't passed properly.
svn path=/nixos/trunk/; revision=18047
2009-10-30 08:49:35 +00:00
Nicolas Pierron c195493a32 * Add a hacky for-loop to fix the usage of the continue keyword. (NIXOS-85)
The continue keyword was previously used to mount the next device, but
  the loop in has been removed. (see r17919)

svn path=/nixos/trunk/; revision=17973
2009-10-27 10:45:18 +00:00
Eelco Dolstra 1e1ae9cd1e * Don't squeeze all the filesystem option values into one environment
variable, since they might get confused (NIXOS-84).

svn path=/nixos/trunk/; revision=17919
2009-10-22 07:46:30 +00:00
Eelco Dolstra eba8f94069 * jobAttrs -> jobs.
svn path=/nixos/trunk/; revision=17769
2009-10-12 18:09:34 +00:00
Eelco Dolstra e91d882a94 * Converted modules that were still using the old (concrete syntax)
style of declaring Upstart jobs.  While at it, converted them to the
  current NixOS module style and improved some option descriptions.
  Hopefully I didn't break too much :-)

svn path=/nixos/trunk/; revision=17761
2009-10-12 16:36:19 +00:00
Eelco Dolstra 684eb63658 * fsck is no longer in e2fsprogs.
* Don't try to remount CIFS filesystems.
* For devices specified by label, use /dev/disk/by-label instead of
  LABEL=.  The initrd already did this.
* Improved the flagging of pseudo devices.

svn path=/nixos/trunk/; revision=17431
2009-09-25 22:38:37 +00:00
Eelco Dolstra 39d1b11ff7 * The mount hack is gone, just use the regular mount from
util-linux-ng and make sure that the needed mount helpers
  (e.g. ntfs3g) are in /var/lib/current-system/sw/sbin.

svn path=/nixos/trunk/; revision=16690
2009-08-11 21:10:33 +00:00
Eelco Dolstra 0e3bef4195 * Declare the type of jobs.
svn path=/nixos/branches/modular-nixos/; revision=16375
2009-07-15 13:41:00 +00:00
Eelco Dolstra b84bab7873 * Use the relatime mount option by default. (This is the default
anyway in Linux 2.6.30.)

svn path=/nixos/branches/modular-nixos/; revision=16348
2009-07-14 12:07:17 +00:00
Eelco Dolstra f258edcb80 * autocreate should be a boolean.
svn path=/nixos/branches/modular-nixos/; revision=15956
2009-06-14 11:07:44 +00:00
Nicolas Pierron 4001b66c88 Move the option declaration of filesystems.*.neededForBoot to boot/stage-1.nix.
svn path=/nixos/branches/modular-nixos/; revision=15940
2009-06-11 16:04:03 +00:00
Nicolas Pierron 0657b26ab1 Use types in to improve filesystems.nix
svn path=/nixos/branches/modular-nixos/; revision=15939
2009-06-11 16:03:57 +00:00
Eelco Dolstra a4fa62aaf0 * The fileSystems option shouldn't have a default.
svn path=/nixos/branches/modular-nixos/; revision=15867
2009-06-05 13:30:30 +00:00
Eelco Dolstra fc9111fadf * Move various system initialisation tasks (e.g. mounting filesystems,
initialising network interfaces, etc.) to modules/tasks.  This
  follows the Upstart terminology: a service is a job that doesn't
  usually terminate (e.g. a daemon), while a task is a job that does
  some work and then exits.

svn path=/nixos/branches/modular-nixos/; revision=15771
2009-05-28 15:03:05 +00:00
Renamed from upstart-jobs/filesystems.nix (Browse further)