Adott egy "SUSE Linux Enterprise Server 11 SP3 (x86_64)"
Bizonyos okokból -- és most ne azokat firtassuk, és ne
próbáljunk kerülőutat találni, mert ez már a kerülőút --
azt vettem a fejembe, hogy az ntpd ne a /etc/ntp.conf, hanem
a /etc/ntp.conf.real file-t tekintse konfigjának.
Az init scriptben át is írtam: NTP_CONF="/etc/ntp.conf.real"
A file létezik, olvasható:
# find /etc /var/lib -name '*ntp.conf*' -ls
4675097 4 -rw-r--r-- 1 root root 2408 Aug 25 2013
/etc/ntp.conf
4676236 4 -rw-r--r-- 1 root root 2155 Mar 17 12:34
/etc/ntp.conf.real
8676929 4 -rw-r----- 1 root ntp 2028 May 8 2013
/var/lib/ntp/etc/ntp.conf.iburst
8678340 4 -rw-r--r-- 1 root root 2430 Jan 9 11:17
/var/lib/ntp/etc/ntp.conf
8676731 4 -rw-r--r-- 1 root root 2155 Mar 17 12:34
/var/lib/ntp/etc/ntp.conf.real
#
Az ntpd ugyan úgy van idomítva, hogy chrootoljon a /var/lib/ntp/-be,
de még mielőtt odáig jutna, megbotlik:
Mar 17 13:03:30 service0 ntpd[6132]: getconfig: Couldn't open
</etc/ntp.conf.real>
A strace ezt mutatja:
6132 open("/etc/ntp.conf.real", O_RDONLY) = -1 EACCES (Permission denied)
6132 write(2, "getconfig: Couldn't open </etc/n"..., 46) = 46
Nincs POSIX ACL, file attribútum, és tudtommal SE Linux sem.
Utóbbiról -- bevallom -- nem tudom hogy kellene meggyőződnöm.
A strace szerint az init script és az általa indított programok (cp,
awk) sikeresen megnyitják a file-t:
6115 stat("/etc/ntp.conf.real", {st_dev=makedev(8, 6), st_ino=4676236,
st_mode=
S_IFREG|0644, st_nlink=1, st_uid=0, st_gid=0, st_blksize=4096,
st_blocks=8, st_s
ize=2155, st_atime=2014/03/17-12:34:32, st_mtime=2014/03/17-12:34:12,
st_ctime=2
014/03/17-12:34:13}) = 0
6122 open("/etc/ntp.conf.real", O_RDONLY) = 3
6123 open("/etc/ntp.conf.real", O_RDONLY) = 3
6115 stat("/etc/ntp.conf.real", {st_dev=makedev(8, 6), st_ino=4676236,
st_mode=
S_IFREG|0644, st_nlink=1, st_uid=0, st_gid=0, st_blksize=4096,
st_blocks=8, st_s
ize=2155, st_atime=2014/03/17-12:34:32, st_mtime=2014/03/17-12:34:12,
st_ctime=2
014/03/17-12:34:13}) = 0
6115 access("/etc/ntp.conf.real", R_OK) = 0
6128 stat("/etc/ntp.conf.real", {st_dev=makedev(8, 6), st_ino=4676236,
st_mode=
S_IFREG|0644, st_nlink=1, st_uid=0, st_gid=0, st_blksize=4096,
st_blocks=8, st_s
ize=2155, st_atime=2014/03/17-12:34:32, st_mtime=2014/03/17-12:34:12,
st_ctime=2
014/03/17-12:34:13}) = 0
Csak a nyüves ntpd-nek nem megy. Valami bujkál a háttérben,
amiről nem tudok. De mi lehet az?
kissg
--
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?
_________________________________________________
linux lista - [email protected]
http://mlf.linux.rulez.org/mailman/listinfo/linux