[Solved] Systemd automounts /boot (was mlocate not traversing /boot)

For some reason, mlocate does not index my /boot:
┌─[Shiv ~ ]
└─╼ locate vmlinuz-linux
/home/jason/Build/chroot/root/boot/vmlinuz-linux
┌─[Shiv ~ ]
└─╼ sudo updatedb -U /boot
[sudo] password for jason:
┌─[Shiv ~ ]
└─╼ locate vmlinuz-linux
/boot/vmlinuz-linux
/boot/vmlinuz-linux-jwr
┌─[Shiv ~ ]
└─╼ sudo updatedb
┌─[Shiv ~ ]
└─╼ locate vmlinuz-linux
/home/jason/Build/chroot/root/boot/vmlinuz-linux
My /etc/updatedb.conf is the stock Arch one, /boot is obviously mounted (as the -U switch works), but a plain updatedb does not return any results from /boot.
I recently moved my ESP from /boot/efi to /boot, and as this is the only machine exhibiting this behaviour, it leads me to suspect something is amiss here.
My fstab:
# ESP: /dev/sda1
UUID=696A-09B3 /boot vfat defaults,relatime,discard 0 2
# /dev/mapper/vgroup-lvroot
UUID=1d2dfd7d-adeb-4786-ag98-c8fg675f8e2f / ext4 rw,relatime,discard,data=ordered 0 1
# /dev/mapper/vgroup-lvhome
UUID=50798021-94b5-4011-a593-9087gfhcd59b8 /home ext4 rw,relatime,discard 0 2
Am I missing something obvious?
# edit: updated thread title with the cause, as opposed to the symptom...

WonderWoofy wrote:There is a mechanism in systemd (or maybe gummiboot) that mounts the ESP on /boot as a systemd autostart unit.  So it shows up as autofs, which mlocate does not venture into.
Bingo!
┌─[Shiv ~ ]
└─╼ mount | grep boot
systemd-1 on /boot type autofs (rw,relatime,fd=36,pgrp=1,timeout=300,minproto=5,maxproto=5,direct)
/dev/sda1 on /boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro,discard)
falconindy wrote:If there's one thing I've learned about remote debugging over the years, it's to not trust people.
Especially Antipodeans
lolilolicon wrote:I Googled for this and found this relevant talk in our (duh) wiki
I spent some time yesterday searching, but missed this--to my shame
65kid on the wiki wrote:* this feature isn't even documented in systemd yet
Great. Any way to suppress this?

Similar Messages

  • [SOLVED] systemd & separate /boot causing boot failure

    I'm working on moving to systemd, and I'm having a boot issue. I don't think my setup is particularly peculiar, but essentially: I have 2 disks, sda and sdb. sda contains some windows partitions, and /dev/sda4 is my data/homedir partition. /dev/sdb holds my arch install:
    /dev/sda4 - /home (btrfs) (no label)
    /dev/sdb1 - /boot (ext2) label=arch-boot
    /dev/sdb2 - swap label=arch-swap
    /dev/sdb3 - / (btrfs) label=arch-root
    I have the expected entries in /etc/fstab:
    UUID=XXXX / btrfs default 0 1
    UUID=XXXX /boot ext2 defaults 0 1
    UUID=XXXX /home btrfs defaults,relatime,ssd 0 1
    UUID=XXXX swap swap defaults 0 0
    This worked fine under initscripts (again, nothing hugely weird here), but under systemd what effectively happens is the various devices seem to be automounted by systemd, as well as being mounted via fstab. So, during boot I get mounts:
    /dev/sdb3 on /media/arch-root type btrfs
    /dev/sdb1 on /media/arch-boot type ext4
    /dev/sda4 on /media/usbhd-sda4
    as well as the "fstab versions":
    /dev/sdb3 on / type btrfs
    /dev/sda4 on /home type btrfs
    Notably, the "fstab version" of /boot is missing. During boot, the 'boot.mount' unit fails, with:
    mount: /dev/sdb1 is already mounted or /boot busy
    mount: /dev/sdb1 is already mounted on /media/arch-boot
    And bootup stops. Manually invoking "mount /boot" fails with the same error. I see the "automount" unit:
    $ systemctl|grep boot.mount
    boot.mount load failed failed /boot
    media-arch\x2dboot.mount load active mounted /media/arch-boot
    So, I can then issue:
    $ systemctl stop 'media-arch\x2dboot.mount'
    $ systemctl start 'boot.mount'
    Which does successfully unmount the "automount" version, and mount the "fstab version", and I can then exit the emergency shell and boot normally. However, I am unable to issue, say "systemctl disable 'media-arch\x2dboot.mount'"; I simply get a complaint of "Failed to issue method call: No such file or directory." This probably makes sense, and comes down to a misunderstanding on my part between units, services, targets, etc.
    I'm assuming it's *not* expected that we just allow all devices to be automounted (i.e. just remove my /boot entry from fstab)? How can I mark these entries as "do not automatically create mount points under /media"? Or, alternatively, make sure the fstab entries are loaded first, obviating the need for the automount? I'm guessing I'm missing something obvious here as I doubt this is a strange setup, but unfortunately I haven't had much google success when my search criteria are "systemd" and "/boot"...
    Last edited by nogoma (2012-08-16 14:10:34)

    So, this was actually not systemd related, as I discovered when I booted under initscripts again. Essentially, I had an overly general rule in /etc/udev/rules.d that was causing the automount behavior; restricting the matching devices to my non-boot disks fixed the issue.

  • [SOLVED]Systemd: noftify-send running but not displaying

    Hello,
    I'm trying to get systemd to run a command that pops a notification on screen for me to get up and move around a bit (for my health). The script works if called in the command line and seems to be running fine in systemd. No notification is being displayed, however:
    script:
    #!/bin/bash
    notify-send "Get up and move around!" "You've been sitting in one place for too long." --icon=dialog-information
    Service is called move.service. Here is output of systemctl status move.service.
    ● move.service - Reminds you to move.
    Loaded: loaded (/etc/systemd/system/move.service; enabled)
    Active: inactive (dead) since Sat 2014-11-29 09:39:07 EST; 21s ago
    Process: 3797 ExecStart=/bin/bash /mnt/storage/kale/.Resources/scripts/move-around.sh (code=exited, status=0/SUCCESS)
    Main PID: 3797 (code=exited, status=0/SUCCESS)
    If I read this correctly, it executed as PID 3797 and finished 21 seconds ago (hence the dead state in active).
    Here it is while running
    ● move.service - Reminds you to move.
    Loaded: loaded (/etc/systemd/system/move.service; enabled)
    Active: active (running) since Sat 2014-11-29 09:49:11 EST; 11ms ago
    Main PID: 4062 (bash)
    CGroup: /system.slice/move.service
    ├─4062 /bin/bash /mnt/storage/kale/.Resources/scripts/move-around....
    └─4063 notify-send Get up and move around! You've been sitting in ...
    Nov 29 09:49:11 Uberziet systemd[1]: Starting Reminds you to move....
    Nov 29 09:49:11 Uberziet systemd[1]: Started Reminds you to move..
    Thanks
    Last edited by Kale Good (2014-11-29 15:48:11)

    Hello
    I would not use systemd to do that.
    Just write a script and have it running in background when you start your graphical session:
    #!/bin/bash
    while true; do
    notify-send "Get up and move around!" "You've been sitting in one place for too long." --icon=dialog-information
    sleep 7200
    done
    You can also look at this thread for other less KISS ways.

  • [SOLVED] systemd-fsck prolongs boot time considerably

    Hi folks, I've searched but come up blank on this one...
    I've just migrated fully to systemd and all's working well apart from my boot hanging for around 16 seconds on fsck. Disabling the checks via the final column of fstab reduces my boot to under 9 seconds, which is roughly what it was with initscripts. Boot drive's an SSD, all other partitions on 2 SATA HDDs.
    Here are the relevant parts of fstab
    # /dev/sda3 - Backup
    # ========= ------
    UUID=7e23c7f4-acf6-477c-9705-15ae8870181e /media/Backup ext4 defaults 0 2
    # /dev/sdb2 - ROOT (+/home)
    # ========= ------------
    UUID=ee99e089-a642-41c8-b1f4-5dc80307d438 / ext4 defaults,noatime,discard 0 1
    # /dev/sdc1 - Data
    # ========= ----
    UUID=66c7a8dd-8d92-4353-a4eb-1da425449322 /media/Data ext4 defaults 0 2
    # /dev/sdc2 - Scratch
    # ========= -------
    UUID=a8ca4753-ccca-4360-b702-8c12004bf8f8 /media/Scratch ext4 defaults,noatime 0 2
    # /dev/sdc4 - bootISOs
    # ========= --------
    UUID=eea21a23-b3fa-479d-8a62-2502f4f9edfc /media/bootISOs ext4 defaults,noatime 0 2
    I do have /var on the "Data" partition and a few other relocations...
    /media/Data/var /var none bind 0 0
    /media/Data/logs /home/paul/.logs none bind 0 0
    tmpfs /home/paul/.thumbnails tmpfs nodev,nosuid,noatime 0 0
    tmpfs /home/paul/.Skype/Logs tmpfs nodev,nosuid,noatime 0 0
    tmpfs /media/Data/wine/drive_c/windows/temp tmpfs nodev,nosuid,noatime 0 0
    Without fsck
    $ systemd-analyze
    Startup finished in 1280ms (kernel) + 2220ms (initramfs) + 5112ms (userspace) = 8614ms
    With fsck (typical)
    $ systemd-analyze
    Startup finished in 1276ms (kernel) + 3224ms (initramfs) + 20327ms (userspace) = 24829ms
    Any ideas as to the slowdown or is this to be expected with this many partitions?
    Thanks.
    Last edited by fabertawe (2012-09-06 17:48:57)

    WorMzy wrote:You can add "noauto,x-systemd.automount" to the options of non-essential partitions. That may speed up your boot time.
    Sorry, I should have mentioned I already tried this with the "Data" partition and just got a permanent hang in the boot sequence.
    Edit: I've had 2 boots where it's not had the delay but I've no idea why, nothing was changed.
    Edit2: Seems I was too quick to dismiss "noauto,x-systemd.automount"... I've applied it to all partitions except "Data" (and root, obviously) and now I'm consistently getting boot times under 9 seconds. Marking this thread as solved. Thanks to all who contributed
    Last edited by fabertawe (2012-09-06 17:45:48)

  • [SOLVED] systemd 207, lvm2 and luks booting issue

    Hi
    i'm using an encrypted lvm (luks) on my notebook.
    /boot on /dev/sda1
    lvm on    /dev/sda2
                 main-root
                 main-home
                 main-swap
    since the systemd 207 upgrade i am unable to boot my system.
    this error appears at startup:
    A start job is running for dev-mapper-main\x2droot.device
    so i'm guessing that systemd is unable to use the encrypted lvm2, since this error is aknowledged on the
    after checking some threads i tried:
    mkinitcpio -p linux
    but there was no effect.
    HOOKS="base systemd autodetect block keymap encrypt lvm2 filesystems fsck vbox
    some people tried suggesting downgrading to systemd 204 but i dont have any pkg file and building with abs leads to the following error
    while makepkg -s:
    ==> Starting prepare()...
    patching file src/core/swap.c
    Hunk #1 FAILED at 220.
    1 out of 1 hunk FAILED -- saving rejects to file src/core/swap.c.rej
    ==> ERROR: A failure occured in prepare().
    Aborting...
    am i supposed to remove the patches from the build? i'm not really sure and more of a beginner in this area.
    Can anyone help me solve either the build or the boot issue ?
    i should mention that i am only able to access my system by using chroot from an arch boot stick.
    Thank you so much.
    Kind Regards
    Last edited by ziv667 (2013-10-01 11:27:06)

    https://wiki.archlinux.org/index.php/Mk … mmon_hooks
    systemd: This will install a basic systemd setup in your initramfs, and is meant to replace the 'base', 'usr', 'udev' and 'timestamp' hooks. Other hooks (like encryption) would need to be ported, and may not work as intended. As of systemd 207, this hook does not work as intended when combined with lvm2 and may break your boot. You also may wish to still include the 'base' hook (before this hook) to ensure that a rescue shell exists on your initramfs.
    Have you tried keeping udev instead of replacing it with systemd hook?
    Have you tried https://wiki.archlinux.org/index.php/Ar … ck_Machine ? It has systemd 204.
    Last edited by karol (2013-10-01 11:16:57)

  • [SOLVED] systemd boot fails - Removable on fstab

    Just converted to the dark (systemd) side.
    Very straight forward, simple and easy enough.
    I have one problem with boot process.
    I have three usb devices that i use frequently, below is my fstab
    # Removable Media
    UUID=6e4bc1aa-3414-48b9-9598-5eedfaadbe2b /media/FreeAgent1 ext4 defaults,user 0 0
    UUID=14219291-0703-45b6-95db-976c5b7c3b7b /media/FreeAgent2 ext4 defaults,user 0 0
    UUID=0590bbe0-d098-4f81-a9c7-c72654aa54a5 /media/Sandisk ext4 defaults,user 0 0
    USB devices at the moment arent on the pc.
    With init process, everything was fine.
    Boot process gave me prompt.
    With systemd, my archlinux box doesnt boot (at all)
    http://ebalaskas.gr/img/systemd_removeable.png
    Reading https://bbs.archlinux.org/viewtopic.php?id=146982 & http://lists.freedesktop.org/archives/s … 06292.html
    i get the feeling that perhaps is a bug.
    But i am not sure.
    The emergency mode (^D) doesnt work either - keyboard seemed dead.
    Used old transitional init=/bin/sh to comment out the removable devices from my fstab
    -- mod edit: read the Forum Etiquette and only post thumbnails http://wiki.archlinux.org/index.php/For … s_and_Code [jwr] --
    Last edited by ebal (2012-08-24 06:43:52)

    ebal wrote:
    Nothing is needed to be done to fstab file !
    it shouldnt
    it mustnt
    with the heck i must edit my fstab cause systemd doesnt have a proper function to timeout when there are devices that are not present at boot time !!!
    That dont even make sense.
    Thank you all for your answers but PLZ ... try to focus on the actual problem that systemd is failing to boot and not to fstab !
    btw from my first post i 've already mentioned that i commented out these entries just to boot with systemd.
    what is the problem with using nofail or noauto,x-systemd.automount? systemd does the right thing here, it tries to mount the device on boot and waits for it - it's just that the timeout is very long (afaik 90 seconds).
    the only reason this worked with initscripts is that afaik initscripts just tries to mount the device and won't wait for it if it isn't there, but instead just fails immediately. While this worked, it was still the wrong approach. You should have added noauto or nofail in the first place.

  • [SOLVED] Systemd and Sshfs Automount

    Hi,
    I'm trying to set up automount on an sshfs drive. From other posts I already concluded this line for my /etc/fstab:
    [email protected]:/users/schnitzl /home/ben/data/mnt/uni/ fuse.sshfs noauto,x-systemd.automount,users,idmap=user,IdentityFile=/home/ben/.ssh/id_rsa,allow_other,reconnect 0 0
    But yet it does not work. Whilst logging into the remote Host from command line is no problem:
    ssh [email protected],
    automounting fails:
    -- cd uni/
    bash: cd: uni/: No such device.
    journalctl -b | grep uni tells me:
    Nov 15 16:31:31 mario systemd[1]: Mounting /home/ben/data/mnt/uni...
    Nov 15 16:31:31 mario systemd[1]: Mounted /home/ben/data/mnt/uni.
    Nov 15 16:31:31 mario systemd[1]: home-ben-data-mnt-uni.mount mount process exited, code=exited status=1
    Nov 15 16:31:31 mario systemd[1]: Unit home-ben-data-mnt-uni.mount entered failed state.
    Any Ideas?
    Benjamin
    Edit: Which services do I have to restart, in order to let systemd reload the /etc/fstab configuartion?
    Last edited by Lord Bo (2012-11-15 17:06:55)

    Thank you very much! That was the right option! I already had it there, but as it did not work yet, I altered the line and forgot to add this option... . However: one last thing: Which services do I have to restart, after having altered /etc/fstab in order to take changes into effect? It is a bit annoying always having to restart the whole system.
    Edit:
    teekay wrote:EDIT: sorry, I oversaw the noauto. So you want on-demand, right? https://bbs.archlinux.org/viewtopic.php?id=146674
    Well it is now mounted on demand (as soon, as I try to access the directory).
    And the link you provided: I already found that during my researches, but the crucial point was, as you mentioned, the missing _netdev option. However: Thanks again .
    Last edited by Lord Bo (2012-11-15 16:54:52)

  • [SOLVED]systemd-timesyncd is not syncing time

    Quick solution:
    1) Check that systemd-networkd is running (if not, start it)
    2) If it is running and timesyncd is not syncing, just restart systemd-networkd
    more on this in the last post.
    Hello,
    I tried to replace ntp with systemd-timesyncd. I disabled ntpd, enabled systemd-timesyncd, enabled and set systemd-networkd (I found that it might help) over netctl (which I could uninstall then). It somehow worked for few reboots, but then it stopped. Of course there must be a reason why, but I can't figure out what it could be. Everything looks fine to me, but time is just not syncing and I'm 30 minutes in the past (compared with realtime). It loads saved time (as fake-hwclock does), but then there is no sync.
    Here are my logs:
    ~ $ systemctl status systemd-networkd systemd-timedated systemd-timesyncd
    * systemd-networkd.service - Network Service
    Loaded: loaded (/usr/lib/systemd/system/systemd-networkd.service; enabled)
    Active: active (running) since Sun 2014-06-08 16:48:36 CEST; 15h ago
    Docs: man:systemd-networkd.service(8)
    Main PID: 149 (systemd-network)
    Status: "Processing requests..."
    CGroup: /system.slice/systemd-networkd.service
    `-149 /usr/lib/systemd/systemd-networkd
    Jun 08 16:48:36 smecpi systemd[1]: Starting Network Service...
    Jun 08 16:48:36 smecpi systemd-networkd[149]: eth0: link configured
    Jun 08 16:48:36 smecpi systemd[1]: Started Network Service.
    Jun 08 16:48:37 smecpi systemd-networkd[149]: eth0: gained carrier
    * systemd-timedated.service - Time & Date Service
    Loaded: loaded (/usr/lib/systemd/system/systemd-timedated.service; static)
    Active: active (running) since Mon 2014-06-09 08:14:05 CEST; 11min ago
    Docs: man:systemd-timedated.service(8)
    man:localtime(5)
    http://www.freedesktop.org/wiki/Software/systemd/timedated
    Main PID: 4520 (systemd-timedat)
    CGroup: /system.slice/systemd-timedated.service
    `-4520 /usr/lib/systemd/systemd-timedated
    Jun 09 08:14:05 smecpi systemd[1]: Started Time & Date Service.
    * systemd-timesyncd.service - Network Time Synchronization
    Loaded: loaded (/usr/lib/systemd/system/systemd-timesyncd.service; enabled)
    Active: active (running) since Sun 2014-06-08 16:48:35 CEST; 15h ago
    Docs: man:systemd-timesyncd.service(8)
    Main PID: 125 (systemd-timesyn)
    CGroup: /system.slice/systemd-timesyncd.service
    `-125 /usr/lib/systemd/systemd-timesyncd
    Jan 01 01:00:06 smecpi systemd-timesyncd[125]: System clock time unset or jumped backwards, restoring from recorded timestamp: Sun 2014-06-08 16:48:35 CEST
    Jun 08 16:48:35 smecpi systemd[1]: Started Network Time Synchronization.
    ~ $ timedatectl
    Local time: Mon 2014-06-09 08:29:51 CEST
    Universal time: Mon 2014-06-09 06:29:51 UTC
    RTC time: n/a
    Time zone: Europe/Prague (CEST, +0200)
    NTP enabled: yes
    NTP synchronized: no
    RTC in local TZ: no
    DST active: yes
    Last DST change: DST began at
    Sun 2014-03-30 01:59:59 CET
    Sun 2014-03-30 03:00:00 CEST
    Next DST change: DST ends (the clock jumps one hour backwards) at
    Sun 2014-10-26 02:59:59 CEST
    Sun 2014-10-26 02:00:00 CET
    Any ideas?
    Last edited by Kotrfa (2014-06-11 16:30:15)

    Ok, thank you for your help. I signed a bug here: https://bugs.freedesktop.org/show_bug.cgi?id=79836 .
    Edit:
    So here is a little help. timesyncd just waits for "network configuration change". I guess that (somehow) timesyncd is runned after networkd and then waits for change. All you have to do is
    systemctl restart systemd-networkd
    Here is example and steps to reproduce (after boot up, both networkd and timesyncd are enabled):
    ~ $ systemctl status systemd-timesyncd systemd-networkd
    * systemd-timesyncd.service - Network Time Synchronization
    Loaded: loaded (/usr/lib/systemd/system/systemd-timesyncd.service; enabled)
    Active: active (running) since Wed 2014-06-11 17:55:50 CEST; 24min ago
    Docs: man:systemd-timesyncd.service(8)
    Main PID: 126 (systemd-timesyn)
    CGroup: /system.slice/systemd-timesyncd.service
    `-126 /usr/lib/systemd/systemd-timesyncd
    Jun 01 01:00:06 locsmxp systemd-timesyncd[126]: System clock time unset or jumped backwards, restoring from recorded timestamp:...0 CEST
    Jun 11 17:55:50 locsmxp systemd[1]: Started Network Time Synchronization.
    * systemd-networkd.service - Network Service
    Loaded: loaded (/usr/lib/systemd/system/systemd-networkd.service; enabled)
    Active: active (running) since Wed 2014-06-11 17:55:51 CEST; 24min ago
    Docs: man:systemd-networkd.service(8)
    Main PID: 150 (systemd-network)
    Status: "Processing requests..."
    CGroup: /system.slice/systemd-networkd.service
    `-150 /usr/lib/systemd/systemd-networkd
    Jun 11 17:55:51 locsmxp systemd[1]: Started Network Service.
    Jun 11 17:55:51 locsmxp systemd-networkd[150]: eth0: link configured
    Jun 11 17:55:52 locsmxp systemd-networkd[150]: eth0: gained carrier
    Hint: Some lines were ellipsized, use -l to show in full.
    now restart networkd:
    ~ $ systemctl restart systemd-networkd
    and result:
    ~ $ systemctl status systemd-timesyncd systemd-networkd
    * systemd-timesyncd.service - Network Time Synchronization
    Loaded: loaded (/usr/lib/systemd/system/systemd-timesyncd.service; enabled)
    Active: active (running) since Wed 2014-06-11 17:55:50 CEST; 25min ago
    Docs: man:systemd-timesyncd.service(8)
    Main PID: 126 (systemd-timesyn)
    Status: "Using Time Server 216.239.32.15:123 (time2.google.com)."
    CGroup: /system.slice/systemd-timesyncd.service
    `-126 /usr/lib/systemd/systemd-timesyncd
    Jun 01 01:00:06 locsmxp systemd-timesyncd[126]: System clock time unset or jumped backwards, restoring from recorded timestamp:...0 CEST
    Jun 11 17:55:50 locsmxp systemd[1]: Started Network Time Synchronization.
    Jun 11 18:20:48 locsmxp systemd-timesyncd[126]: Network configuration changed, trying to establish connection.
    Jun 11 18:20:48 locsmxp systemd-timesyncd[126]: Network configuration changed, trying to establish connection.
    Jun 11 18:20:48 locsmxp systemd-timesyncd[126]: Using NTP server 216.239.32.15:123 (time2.google.com).
    Jun 11 18:20:49 locsmxp systemd-timesyncd[126]: interval/delta/delay/jitter/drift 64s/+0.000s/0.000s/0.000s/+0ppm
    * systemd-networkd.service - Network Service
    Loaded: loaded (/usr/lib/systemd/system/systemd-networkd.service; enabled)
    Active: active (running) since Wed 2014-06-11 18:20:48 CEST; 5s ago
    Docs: man:systemd-networkd.service(8)
    Main PID: 1129 (systemd-network)
    Status: "Processing requests..."
    CGroup: /system.slice/systemd-networkd.service
    `-1129 /usr/lib/systemd/systemd-networkd
    Jun 11 18:20:48 locsmxp systemd-networkd[1129]: eth0: gained carrier
    Jun 11 18:20:48 locsmxp systemd[1]: Started Network Service.
    Jun 11 18:20:48 locsmxp systemd-networkd[1129]: eth0: link configured
    Hint: Some lines were ellipsized, use -l to show in full.
    I solved this issue by adding new service (guide here: https://wiki.archlinux.org/index.php/Sy … rocess.3F) which runs this simple script
    #!/usr/bin/bash
    sleep 15
    systemctl restart systemd-networkd
    So workaround...
    Last edited by Kotrfa (2014-06-11 16:46:06)

  • [solved] systemd 219: automount doesn't work anymore

    To mount a directory with sshfs on another Arch system in my local net I added this to fstab:
    [email protected]:/var/cache/pacman/pkg /var/cache/pacman/pkg fuse.sshfs x-systemd.automount,_netdev,user,noatime,idmap=user,transform_symlinks,identityfile=/root/.ssh/id_rsa,allow_other,default_permissions,reconnect 0 0
    I need it to use a local pacman directory globally so new packages will be downloaded only once for all my Arch pc's.
    This has worked for a long time but since systemd 219-1 nothing happens. Mounting it manually using fstab works. I switched back to systemd 218-2 and it works fine again.
    Thanks, lw.
    Last edited by LessWire (2015-03-16 14:41:09)

    Same here for cifs and ntfs4 mounts in fstab. Downgrade from 219-2 to 218-2 fixes this.
    Example fstab entry:
    //sambaserver/myshare /home/me/server/myshare cifs x-systemd.automount,sec=ntlmv2,nobrl,user=me,password=mypw,workgroup=My.LAN 0 0
    works with 218-2 but not with 219-2. Timing issue?
    Manually mounting the directories on console after boot works:
    mount //sambaserver/myshare
    Harvey

  • [Solved] systemd creates autofs after unmounting /boot

    After logging in, i unmount /boot, so that i can unplug the usb drive where it resides, then systemd creates this mount:
    # mount | grep /boot
    systemd-1 on /boot type autofs (rw,relatime,fd=26,pgrp=1,timeout=300,minproto=5,maxproto=5,direct)
    Typing this hangs forever:
    ls /boot
    /etc/fstab
    UUID=2D75-67FC /boot vfat rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro,nodev,nosuid,noexec 0 2
    I don't really know what to make of this. Seems like a bug, given that ls hangs forever instead of showing nothing.
    Last edited by teateawhy (2014-09-12 10:48:38)

    My bad, i really masked the mount unit. Will try again tomorrow.
    EDIT:
    After masking the automount unit, it looks like this:
    * /boot is mounted correctly at startup
    * after unmounting /boot manually, no autofs mount shows up anymore
    * ls does not hang and immediatly shows nothing, as expected
    # systemctl status boot.automount
    ● boot.automount
    Loaded: masked (/dev/null)
    Active: inactive (dead)
    # mount | grep /boot
    (No output)
    Last edited by teateawhy (2014-09-12 10:16:50)

  • After upgrading to osx 10.9.3, my external hard drive was not able to mount, but it can be mounted without issue in osx 10.6, how do I solve it? it was formatted by disk utility.

    Hi
    After upgrading to osx 10.9.3, my external hard drive was not able to mount, but it can be mounted without issue in osx 10.6, how do I solve it? it was formatted by disk utility.
    Thanks
    PT

    From the menu bar, select
     ▹ System Preferences ▹ Energy Saver ▹ Power Adapter  
    and uncheck the box labeled Put the hard disk(s) to sleep when possible, if it's checked.
    If the drive has more than one interface (USB, FireWire, Thunderbolt, eSATA), try one of the other interfaces.
    Check that the data cable is securely inserted at both ends.
    Try a different cable.
    If you're connecting the drive through a hub, connect it directly to a built-in port on the Mac.
    If you're connecting it directly, try a different port.
    Disconnect all other devices on the bus, or as many as possible.
    Test the drive with another Mac. Test another drive with this Mac.
    If the drive is bus-powered, but has an AC adapter, connect the adapter.
    Start up in Recovery mode and launch Disk Utility. Is the drive recognized?
    Start up in Safe Mode and test.
    Reset the NVRAM.
    Reset the System Management Controller.
    If the drive doesn't work under any of the above conditions, and if another drive does work with the same Mac, then the drive has failed. You may be able to salvage the mechanism by removing it from the enclosure and installing it in another one, or in a drive dock.

  • [SOLVED]systemd and make a camera visible GUI-wise in your filemanager

    After reading a lot about systemd in the wiki and in this forum I understand there are different opionons about systemd. Anyway, I have a adapted all the changes to rc.conf leaving out only a few daemons to start there. So why not give systemd a try? If you dont want to read the full posting I finally got it to work, basically by reading carefully and checking the suggested tests in the systemd wiki. (loginctl)
    As suggested by the wiki, I tried the systemd yesterday. Enabled via systemctl some services to "replace" my rc.conf daemons. I got what I thought everything to work, including autologin directly to my Xfce4 desktop. Everything except the digital camera.
    When starting Arch traditionally via initscripts I immediately can see the camera in the filemanager (Nautilus) when the camera is attached via USB.
    Some minutes later, after adding "init=/usr/lib/systemd/systemd" to the APPEND line in Syslinux and rebooting, my machine reboots
    fine.But when connecting the camera again it is not visible graphically.
    The camera is there because when using gphoto2 (the commandline) as root I can transfer pictures etc.
    Even if I am no happy CLI user I can handle it when necessary. Handling pictures a graphical view of them is much easier...
    As the wiki about systemd says one can try it out. I have not removed anything from the system and when starting Arch again, the initscript way, I can see the camera again in my filemanager, gthumb works again and pictures can be transferred to my machine.
    In the wiki again, this time about digital cameras
    Permission issues
    Camera devices should be granted permission using ACLs. For this to work, users need to have consolekit or systemd running and the user session must be registered with them accordingly.
    Check this using /usr/bin/ck-list-sessions to verify a value of "TRUE" should be returned for both the "active" and "is-local" fields:
    $ ck-list-sessions | grep TRUE
    active = TRUE
    is-local = TRUE
    ACL=Atlantic Container Line is what first comes into my mind. I have had some connections to transport business...I admit I had to google it to find the correct interpretation of this mumbo-jumbo.
    The wiki also gives a "hint", if this is not working try to use the obsolete camera group and edit some udev rules.
    Should not be necessary when it has worked before systemd and earlier experiences
    But what is this about "Permission issues"?  Here is my listings relative the wiki hints. All seems OK.. or why the heck are there two sessions??
    [leif@krasaki ~]$ ck-list-sessions | grep TRUE
    is-local = TRUE
    active = TRUE
    is-local = TRUE
    [leif@krasaki ~]$ ck-list-sessions
    Session1:
    unix-user = '1000'
    realname = '(null)'
    seat = 'Seat1'
    session-type = ''
    active = FALSE
    x11-display = ''
    x11-display-device = ''
    display-device = '/dev/tty1'
    remote-host-name = ''
    is-local = TRUE
    on-since = '2012-10-24T07:12:56.499847Z'
    login-session-id = '1'
    idle-since-hint = '2012-10-24T07:13:26.994037Z'
    Session2:
    unix-user = '1000'
    realname = '(null)'
    seat = 'Seat1'
    session-type = ''
    active = TRUE
    x11-display = ':0'
    x11-display-device = '/dev/tty7'
    display-device = '/dev/tty1'
    remote-host-name = ''
    is-local = TRUE
    on-since = '2012-10-24T07:13:02.361157Z'
    login-session-id = '1'
    [leif@krasaki ~]$
    As one can see, the ACTIVE values are here as the wiki says. But no camera. Those values are the same, wheter which way the machine is started. But 2 sessions??
    Further reading in the systemd wiki article and consolekit vs systemd.logind gives a clue.
    From the wiki:
    In order to check the status of your user session, you can use loginctl. To see if your user session is properly set up, check if the following command contains Active=yes. All polkit actions like suspending the system or mounting external drives with Udisks should then work automatically.
    So when started via systemd and running logintctl, it gives this surprising result. Does not matter wheter as normal user, nor as root....
    [leif@krasaki ~]$ loginctl
    SESSION UID USER SEAT
    1 1000 leif seat0
    1 sessions listed.
    [leif@krasaki ~]$ loginctl show-session 1
    Id=1
    Timestamp=Wed, 24 Oct 2012 10:57:03 +0200
    TimestampMonotonic=20040019
    DefaultControlGroup=name=systemd:/user/leif/1
    VTNr=1
    TTY=tty1
    Remote=no
    Service=login
    Leader=315
    Audit=1
    Type=tty
    Class=user
    Active=no
    State=online
    KillProcesses=no
    IdleHint=yes
    IdleSinceHint=1351069009642296
    IdleSinceHintMonotonic=6664433
    Name=leif
    [leif@krasaki ~]$
    Surprising? Should it not have been Active=Yes? So something is wrong in my settings although it had worked "before" starting using systemd..
    OK, so far. Lost? Not yet. Double check again everything and I found the culprit, my  ~/.bash_profile which had worked before seemed a bit different to what is suggested in the wiki. The old one, actually started 2 sessions, as also could be seen here above checking ck-list-sessions. That was the problem
    Using a fresh edited ~/.bash_profile as suggested here, the camera is visible graphically
    Finally, just for fun, start again the old initscipt way. Enabling daemon and so on. Still 2 sessions going on....Here it was the "/.xinitrc, which also had some old fashions and I removed the ck-launch-session from the exec line. So even here, now only 1 session..
    Anyway, now the camera is visible, both starting with initscripts, naturally also some daemons active in rc.conf and by starting with systemd.
    I rest my case and it seems systemd works with everything on my machine which is just a normal desktop used by an old man.
    Thanks for reading...

    Solved now! Boot times are as fast as posssible on my HDD I think. Only thing after uninstalling initscripst and initscripts-systemd was that locale was not set inspite of a correct /etc/locale.conf. I had to make /etc/profile.d/locale.sh with this content;
    if [ -s /etc/locale.conf ]; then
    . /etc/locale.conf
    fi
    export LANG LANGUAGE LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE
    export LC_MONETARY LC_MESSAGES LC_PAPER LC_NAME LC_ADDRESS
    export LC_TELEPHONE LC_MEASUREMENT LC_IDENTIFICATION

  • [SOLVED] Systemd and tmpfiles? Conflicting /tmp?

    I've got this error in journal;
    systemd-tmpfile[247]: Two or more conflicting lines for /tmp configured, ignoring.
    This is from a leftover from arch initscripts, /usr/lib/tmpfiles.d/arch.conf shich is doubled by systemd's, /usr/lib/tmpfiles.d/x11.conf (almost).
    arch.conf;
    D /tmp 1777 root root 10d
    d /run/daemons 0755 root root -
    d /tmp/.X11-unix 1777 root root 10d
    d /tmp/.ICE-unix 1777 root root 10d
    d /tmp/.XIM-unix 1777 root root 10d
    d /tmp/.font-unix 1777 root root 10d
    d /tmp/.Test-unix 1777 root root 10d
    F /run/utmp 0664 root utmp -
    r /tmp/.X[0-9]-lock
    r /etc/nologin
    r /etc/shutdownpid
    r /forcefsck
    r /fastboot
    x11.conf;
    # This file is part of systemd.
    # systemd is free software; you can redistribute it and/or modify it
    # under the terms of the GNU General Public License as published by
    # the Free Software Foundation; either version 2 of the License, or
    # (at your option) any later version.
    # See tmpfiles.d(5) for details
    # Make sure these are created by default so that nobody else can
    d /tmp/.X11-unix 1777 root root 10d
    d /tmp/.ICE-unix 1777 root root 10d
    d /tmp/.XIM-unix 1777 root root 10d
    d /tmp/.font-unix 1777 root root 10d
    d /tmp/.Test-unix 1777 root root 10d
    # Unlink the X11 lock files
    r /tmp/.X[0-9]*-lock
    Can I delete the arch one - where is it started from at boot? I'm running only systemd and got rid of all arch units. Or can I merge them? I really can't tell which tmpfiles are needed.
    Last edited by swanson (2012-05-31 19:11:46)

    Solved now! Boot times are as fast as posssible on my HDD I think. Only thing after uninstalling initscripst and initscripts-systemd was that locale was not set inspite of a correct /etc/locale.conf. I had to make /etc/profile.d/locale.sh with this content;
    if [ -s /etc/locale.conf ]; then
    . /etc/locale.conf
    fi
    export LANG LANGUAGE LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE
    export LC_MONETARY LC_MESSAGES LC_PAPER LC_NAME LC_ADDRESS
    export LC_TELEPHONE LC_MEASUREMENT LC_IDENTIFICATION

  • [solved] systemd times out waiting for dev-null.device on encrypted fs

    I have a relatively new install of Arch on my laptop. The relevant sections of the drive setup are a luks encrypted root device (with associated unencrypted /boot), and a large ntfs device encrypted with truecrypt. That contains my home directory, which is shared with the Windows 8 dual-boot on the machine.
    I have all this mounted on boot, so my typical usage is to enter my password for the encrypted root, followed by the password for the truecrypt-encrypted data drive, then normal login.
    This has been working fine for a couple of weeks. This afternoon I rebooted my machine from Windows to Linux, at which point the secondary encrypted drive failed to mount. The root device mounts fine.
    On further examination, in the form of journalctl -xb, I'm getting the following errors after mounting the encrypted root device:
    Feb 12 21:29:54 kafka systemd[1]: Job dev-null.device/start timed out.
    Feb 12 21:29:54 kafka systemd[1]: Timed out waiting for device dev-null.device.
    -- Subject: Unit dev-null.device has failed
    -- Defined-By: systemd
    -- Support: http://lists.freedesktop.org/mailman/li … temd-devel
    -- Documentation: http://www.freedesktop.org/wiki/Softwar … e9d022f03d
    -- Unit dev-null.device has failed.
    -- The result is timeout.
    Feb 12 21:29:54 kafka systemd[1]: Dependency failed for Cryptography Setup for cryptdata.
    -- Subject: Unit [email protected] has failed
    -- Defined-By: systemd
    -- Support: http://lists.freedesktop.org/mailman/li … temd-devel
    -- Documentation: http://www.freedesktop.org/wiki/Softwar … e9d022f03d
    -- Unit [email protected] has failed.
    As my root home directory is on the root filesystem, I can still log in as root. If I try to mount or unmount the truecrypt device (located at /data) the command hangs. After removing "auto,x-systemd.automount" from that device from /etc/fstab and rebooting, I have a significant delay at boot, but I can then mount the /data device as normal.
    I can't find anything related to this either here or on Google. Any ideas?
    Last edited by tealeaf (2014-02-13 12:01:55)

    WonderWoofy wrote:A bit OT, but I just want to mention that having your $HOME on ntfs is probably not the best idea either.  It may work, but because it is not a POSIX compliant filesystem, there is a good chance you might run into some issues.
    Thanks for the warning. Sadly, as there are applications I need for work that only run in Windows, I need to dual boot this machine with Windows 8.1. This is the best option I can find for sharing my home directory, which is also a necessity due to the amount of data I have to share between the systems. I would much rather trust to ntfs-3g-ar and its UserMapping (and all the fiddling with ACLs that I had to do) than to the Windows ext2 drivers I can find. They all seem to be several years out of date. Linux is much better at talking NTFS than Windows is at talking EXT. (To be honest, I'm actually quite impressed with Windows 8 since the upgrade to 8.1. As a long term Arch user and a fan of tiling window managers it's interesting to see Windows moving in the right direction. )
    With 'permissions' in the /etc/fstab and the .NTFS-3G/UserMapping file in place it works almost seamlessly. (It took a lot of tinkering with ACLs in Windows and Linux, but it's working very well now. One tip that I'll write here in case it's of use is that you want the last line of the UserMapping file to be a 'generic' mapping. When I didn't have that there were very strange things going on.)
    The only two minor problems I have now are:
    1) A few applications don't like FUSE filesystems. Steam worked for a while and then broke; reinstalling it failed at every stage. When I checked, it seems that FUSE is a known problem for Steam. (I don't think it's restricted to NTFS.) My response to that was to create /home/.local/$HOME on my root (ext4) filesystem and symlink out to it for troublesome applications.
    2) There are a few characters for filenames that Windows doesn't like, making those files inaccessible in Windows. (Colons are the major culprit.) They're usually quite easily renamed. (The exception being my .maildir folder, which I have had to duplicate natively in cygwin.)
    Neither of these are anything more than minor niggles. I appreciate the warning, though.
    Having said that, if you have an alternative that lets me share a truecrypt-encrypted drive between Linux and Windows that is better than the NTFS-3G approach, I'd love to hear it for future reference.

  • Can systemd automounter unmount inactive fileystems?

    Hi,
    tl;dr: Can systemd automounter unmount fileystems after a period of inactivity, like autofs does?
    I've just started discovering the wonderful new world of systemd, and to my great joy I found that it contains an automounter, so I thought that I would be able to use that instead of using autofs.
    The single thing that I like to automount is my home NAS on my laptop (via NFSv4) that I every day take from home to work and then back home.
    To do this with autofs is kind of like killing mosquitoes with a flamethrower. I would much rather just have my automounted NAS defined in my fstab than having to force the slightly mysterious autofs.xxx-files to mount the drive with the options I want it to use.
    So, I got systemd to automount my NAS and all was joy! Until I realized that it wasnt unmounting it after a time of non-use. I have googled quite a bit, searched the forums, but have found no mention that systemd either has or doesnt have this kind of functionality.
    So my purpose with this post is to get a definitive answer, does systemd do this? And if it doesn't, maybe others searching for the same information will end up here, and find the answer...
    /DonO

    I've been having this problem for as long as I can remember. I have finally decided to sit down and work something out instead of my laptop hanging all the time when it can't find the nfs server. The systemd.automount feature is nice, but it really sucks that it does not auto unmount when the share is not found.
    Also, having systemd.automount means that every time I open vim, or a manpage, and there is no network connection, systemd tries to mount the shares. I'm not sure why because I am not directly accessing them. Everything loads slowly when systemd automount is active for my shares and there is no network connection.
    Using soft instead of hard is a workaround, but then when the network connection is lost, corruption can occur.
    It seems like the only way to really solve this problem is to have some kind of script run when the network comes up to mount the shares, and to unmount when it goes down. This would require custom systemd units or something. Diving into the systemd manuals is something I have been putting off because they are so hefty.
    For anyone that is interested, here is my fstab:
    lithium:/mnt/data /mnt/data nfs noauto,noatime,rsize=32768,wsize=32768,soft,retry=0,timeo=3,x-systemd.automount,x-systemd.device-timeout=1ms 0 0
    lithium:/var/cache/pacman /var/cache/pacman nfs noauto,noatime,rsize=32768,wsize=32768,soft,retry=0,timeo=3,x-systemd.automount,x-systemd.device-timeout=1ms 0 0
    Last edited by demizer (2013-07-14 09:00:23)

Maybe you are looking for

  • File names on burned CD's

    Hello, I burned a hybrid CD (default behaviour), from finder and hdiutil makehybrid, readable on mac (HFS+), windows (ISO 9660/Joliet), and linux (ISO 9660/Rock Ridge). The resulting file names differed on each platform: HFS+: Everything as expected.

  • I am trying to download the new CS6 Design Suite - not able to get past the previous version.

    I am trying to downloat the new CS6 Design Suite and am not able to get past the previous version menu. Getting the message "This serial number is not for a qualifying product. Please try another." How do I get past this?

  • Function for dates

    Hi Experts! i want to calculate months b/w 2 dates , is there function for this . can i find days and year  also .plz tell me . thanks.

  • Yosemite update not responding

    Hi, I just update my Air (Early 2014) to Yosemite. At the end of the installation something went wrong. My air is not responding and the installation process is not carried on. It tells me that the installation is finished in about 1 minute but since

  • Investigat​e Internal Error

    Trying to investigare the error´s below but no solution was found. Would be grateful for descriptions and possible solutions. My front panel does not update (redraw) its lower part on the sceen. Same thing when not running the vi and then also the ri