My os: debian9.
The filesystem on my disk:
$ sudo blkid | awk '{print $1 ,$3}'
/dev/sda2: TYPE="ext4"
/dev/sda1: TYPE="vfat"
/dev/sda3: TYPE="ext4"
/dev/sda4: TYPE="ext4"
/dev/sda5: TYPE="swap"
Now to chattr +i
for my /etc/resolv.conf
:
sudo chattr +i /etc/resolv.conf
chattr: Operation not supported while reading flags on /etc/resolv.conf
ls -al /etc/resolv.conf
lrwxrwxrwx 1 root root 31 Jan 8 15:08 /etc/resolv.conf -> /etc/resolvconf/run/resolv.conf
sudo mount -o remount,acl /
sudo chattr +i /etc/resolvconf/run/resolv.conf
chattr: Inappropriate ioctl for device while reading flags on /etc/resolvconf/run/resolv.conf
How to set chattr +i
for my /etc/resolve.conf
?
/dev/sda1
is empty for windows.My debian is installed on
/dev/sda2
$ df Filesystem 1K-blocks Used Available Use% Mounted on udev 1948840 0 1948840 0% /dev tmpfs 392020 5848 386172 2% /run /dev/sda2 95596964 49052804 41644988 55% /
acl
is installed.$ dpkg -l acl Desired=Unknown/Install/Remove/Purge/Hold | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad) ||/ Name Version Architecture Description +++-==============-============-============-================================= ii acl 2.2.52-3+b1 amd64 Access control list utilities
No output info from these findmnt commands:
sudo findmnt -fn / | grep -E "acl|user_xattr" sudo findmnt -fn / | grep vfat sudo findmnt -fn $(dirname $(realpath /etc/resolv.conf)) | grep tmpfs
systemd-resolved
./etc/resolvconf/run
is mounted with atmpfs
filesystem, like the linked question.ls -l /etc/resolvconf/run/resolv.conf
and(cd /etc/resolvconf/run/; until findmnt . ; do cd .. ; done)
resolvconf
package, whose sole purpose is to mangle /etc/resolv.conf - I've said it before butapt-get purge
is effective but unsatisfyingly inadequate, there should be a--kill-it-with-fire
or--banish-to-hell
option for miserable system-breaking junk like that.