× NETGEAR will be terminating ReadyCLOUD service by July 1st, 2023. For more details click here.
Orbi WiFi 7 RBE973
Reply

no swap or root in /etc/fstab?

drfrogsplat
Tutor

no swap or root in /etc/fstab?

I noticed today that the contents of /etc/fstab is rather sparser than one might expect:
LABEL=1af8fdf6:data /data btrfs defaults 0 0

there's no mention of the root partition, nor swap, which I'm pretty sure were in there on OS4 (e.g. see this post about an OS4 fstab)... which isn't a big deal until you do something like try to clear your swap out by running
# sudo swapoff -a && sudo swapon -a

... which on OS6 (with no swap specified in /etc/fstab) results in the swap being turned off, but not back on

i imagine a reboot will fix it, but just wondering why the other mount points aren't listed in /etc/fstab, and am thus quite intrigued as to how they actually get mounted!

I suspect this is probably actually just an OS6 issue, rather than specifically an x86 Legacy OS6 issue, but happen to be on an Ultra 4 in case it matters
Message 1 of 2
siigna
NETGEAR Expert

Re: no swap or root in /etc/fstab?

ReadyNAS OS has a bit different system architecture than RAIDiator, using systemd instead of SysV-style init.

Bringing up the OS array (/dev/md0) is taken care of by the initrd process, but that's always been the case.
Management of the root mount point is taken care of by systemd.
So no need to have it wasting space in fstab.

Same story with the swap space (/dev/md1). What was once part of fstab is now integrated in to systemd.

The proper way to temporarily disable your swap would be to use systemctl:


### I'm on a fresh boot and swap has been setup and enabled.
root@nas-6E-3A-08:~# swapon -s
Filename Type Size Used Priority
/dev/md1 partition 2094844 0 -1

### systemd says swap is active. Your output may vary.
root@nas-6E-3A-08:~# systemctl status dev-md1.swap
dev-md1.swap - md1
Loaded: loaded (/lib/systemd/system/dev-md1.swap; enabled)
Active: active since Sun, 26 Oct 2014 10:56:02 -0700; 1min 41s ago
What: /dev/md1
Process: 4355 ExecDeactivate=/sbin/swapoff /dev/md1 (code=exited, status=0/SUCCESS)
Process: 4366 ExecActivate=/sbin/swapon /dev/md1 (code=exited, status=0/SUCCESS)
CGroup: name=systemd:/system/dev-md1.swap

### Temporarily stop the dev-md1.swap service, which deactivates swap.
root@nas-6E-3A-08:~# systemctl stop dev-md1.swap
root@nas-6E-3A-08:~# swapon -s
Filename Type Size Used Priority

### Start the swap service, activating swap once more.
root@nas-6E-3A-08:~# systemctl start dev-md1.swap
root@nas-6E-3A-08:~# swapon -s
Filename Type Size Used Priority
/dev/md1 partition 2094844 0 -1
Message 2 of 2
Top Contributors
Discussion stats
  • 1 reply
  • 1611 views
  • 0 kudos
  • 2 in conversation
Announcements