Solaris 10을 실행하는 서버에서는 이 명령으로 useradd
새 사용자를 추가할 수 없습니다. 실행하면 useradd -m
홈 디렉터리가 생성되지만 모든 디렉터리의 사용자 ID는 50011입니다.
다음 출력을 참조하십시오.
# useradd -s /bin/bash -m testuser
# echo $?
0
# passwd testuser
passwd: User unknown: testuser
Permission denied
# grep -i testuser /etc/passwd
# ls -lh /etc/passwd
-rw-r--r-- 1 root sys 779 Oct 6 2012 /etc/passwd
# ls -lh /etc/shadow
-r-------- 1 root sys 385 Nov 13 13:50 /etc/shadow
# type useradd
useradd is /usr/sbin/useradd
# useradd -s /bin/bash -d /home/testuser -m testuser
# passwd testuser
passwd: User unknown: testuser
Permission denied
# useradd testuser
# passwd testuser
passwd: User unknown: testuser
Permission denied
# ls -lth /home/ | head -6
total 36
drwxr-xr-x 2 50011 other 512 Nov 13 19:37 test3
drwxr-xr-x 2 50011 other 512 Nov 13 19:36 test2
drwxr-xr-x 2 50011 other 512 Nov 13 19:27 test1
drwxr-xr-x 2 50011 other 512 Nov 13 14:56 testuser
drwxr-xr-x 2 50011 other 512 Nov 13 14:46 test_user
# df -k /home;ls -l@ /usr/sbin/useradd; pkgchk SUNWcsu; grep passwd: /etc/nsswitch.conf
Filesystem kbytes used avail capacity Mounted on
/dev/dsk/c0t0d0s6 20646961 604690 19835802 3% /home
-r-xr-xr-x 2 root sys 40252 Jul 6 2011 /usr/sbin/useradd
passwd: files ldap
# useradd -s /bin/bash -b /export/home -m testuser
UX: useradd: ERROR: invalid syntax.
usage: useradd [-u uid [-o] | -g group | -G group[[,group]...] |-d dir |
-s shell | -c comment | -m [-k skel_dir] | -f inactive |
-e expire | -A authorization [, authorization ...] |
-P profile [, profile ...] | -R role [, role ...] |
-K key=value | -p project [, project ...]] login
useradd -D [-g group | -b base_dir | -f inactive | -e expire
-A authorization [, authorization ...] |
-P profile [, profile ...] | -R role [, role ...] |
-K key=value ... -p project]
# userdel testuser
UX: userdel: ERROR: testuser does not exist.
# truss -t\!memcntl,getuid,door_call,door_info,close,mmap,brk,munmap,lwp_sigmask,sigaction,llseek -f useradd -m -d /tmp/testuser testuser
1064: execve("/usr/sbin/useradd", 0xFFBFFCC4, 0xFFBFFCDC) argc = 5
1064: sysinfo(SI_MACHINE, "sun4v", 257) = 6
1064: resolvepath("/usr/lib/ld.so.1", "/lib/ld.so.1", 1023) = 12
1064: resolvepath("/usr/sbin/useradd", "/usr/sbin/useradd", 1023) = 17
1064: stat64("/usr/sbin/useradd", 0xFFBFF790) = 0
1064: open("/var/ld/ld.config", O_RDONLY) = 3
1064: fstat64(3, 0xFFBFF300) = 0
1064: stat64("/lib/libsecdb.so.1", 0xFFBFEEF0) = 0
1064: resolvepath("/lib/libsecdb.so.1", "/lib/libsecdb.so.1", 1023) = 18
1064: open("/lib/libsecdb.so.1", O_RDONLY) = 3
1064: stat64("/lib/libproject.so.1", 0xFFBFEEF0) Err#2 ENOENT
1064: stat64("/usr/lib/libproject.so.1", 0xFFBFEEF0) = 0
1064: resolvepath("/usr/lib/libproject.so.1", "/usr/lib/libproject.so.1", 1023) = 24
1064: open("/usr/lib/libproject.so.1", O_RDONLY) = 3
1064: stat64("/lib/libc.so.1", 0xFFBFEEF0) = 0
1064: resolvepath("/lib/libc.so.1", "/lib/libc.so.1", 1023) = 14
1064: open("/lib/libc.so.1", O_RDONLY) = 3
1064: stat64("/lib/libnsl.so.1", 0xFFBFEEF0) = 0
1064: resolvepath("/lib/libnsl.so.1", "/lib/libnsl.so.1", 1023) = 16
1064: open("/lib/libnsl.so.1", O_RDONLY) = 3
1064: stat64("/lib/libcmd.so.1", 0xFFBFEEF0) = 0
1064: resolvepath("/lib/libcmd.so.1", "/lib/libcmd.so.1", 1023) = 16
1064: open("/lib/libcmd.so.1", O_RDONLY) = 3
1064: stat64("/lib/libproc.so.1", 0xFFBFEEF0) = 0
1064: resolvepath("/lib/libproc.so.1", "/lib/libproc.so.1", 1023) = 17
1064: open("/lib/libproc.so.1", O_RDONLY) = 3
1064: stat64("/lib/librtld_db.so.1", 0xFFBFEEF0) = 0
1064: resolvepath("/lib/librtld_db.so.1", "/lib/librtld_db.so.1", 1023) = 20
1064: open("/lib/librtld_db.so.1", O_RDONLY) = 3
1064: stat64("/lib/libelf.so.1", 0xFFBFEEF0) = 0
1064: resolvepath("/lib/libelf.so.1", "/lib/libelf.so.1", 1023) = 16
1064: open("/lib/libelf.so.1", O_RDONLY) = 3
1064: stat64("/lib/libctf.so.1", 0xFFBFEEF0) = 0
1064: resolvepath("/lib/libctf.so.1", "/lib/libctf.so.1", 1023) = 16
1064: open("/lib/libctf.so.1", O_RDONLY) = 3
1064: getcontext(0xFFBFF600)
1064: getrlimit(RLIMIT_STACK, 0xFFBFF5E0) = 0
1064: getpid() = 1064 [1063]
1064: setustack(0xFF0B2A88)
1064: sigfillset(0xFF31B3BC) = 0
1064: stat64("/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1", 0xFFBFEA90) = 0
1064: resolvepath("/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1", "/platform/sun4v/lib/libc_psr.so.1", 1023) = 33
1064: open("/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1", O_RDONLY) = 3
1064: sysconfig(_CONFIG_PAGESIZE) = 8192
1064: open("/usr/sadm/defadduser", O_RDONLY) = 3
1064: fstat64(3, 0xFFBFE768) = 0
1064: fstat64(3, 0xFFBFE610) = 0
1064: ioctl(3, TCGETA, 0xFFBFE6F4) Err#25 ENOTTY
1064: read(3, " #\t D e f a u l t v a".., 8192) = 286
1064: read(3, 0x0002B23C, 8192) = 0
1064: getpid() = 1064 [1063]
1064: open("/proc/1064/psinfo", O_RDONLY) = 3
1064: read(3, "02\0\0\0\0\0\001\0\004 (".., 336) = 336
1064: open64("/var/run/name_service_door", O_RDONLY) = 3
1064: fcntl(3, F_SETFD, 0x00000001) = 0
1064: stat("/tmp/testuser", 0xFFBFEBB8) = 0
1064: schedctl() = 0xFF330000
1064: fork1() = 1065
1065: fork1() (returning as child ...) = 1064
1065: getpid() = 1065 [1064]
1065: lwp_self() = 1
1065: open("/dev/null", O_RDWR|O_CREAT|O_TRUNC, 0666) = 1
1065: open("/dev/null", O_RDWR|O_CREAT|O_TRUNC, 0666) = 2
1065: execve("/usr/bin/passmgmt", 0x0002B670, 0x0002C0F4) argc = 29
1065: sysinfo(SI_MACHINE, "sun4v", 257) = 6
1065: resolvepath("/usr/sbin/passmgmt", "/usr/sbin/passmgmt", 1023) = 18
1065: stat64("/usr/sbin/passmgmt", 0xFFBFF680) = 0
1065: open("/var/ld/ld.config", O_RDONLY) = 3
1065: fstat64(3, 0xFFBFF1F0) = 0
1065: stat64("/lib/libsecdb.so.1", 0xFFBFEDE0) = 0
1065: resolvepath("/lib/libsecdb.so.1", "/lib/libsecdb.so.1", 1023) = 18
1065: open("/lib/libsecdb.so.1", O_RDONLY) = 3
1065: stat64("/lib/passwdutil.so.1", 0xFFBFEDE0) Err#2 ENOENT
1065: stat64("/usr/lib/passwdutil.so.1", 0xFFBFEDE0) = 0
1065: resolvepath("/usr/lib/passwdutil.so.1", "/usr/lib/passwdutil.so.1", 1023) = 24
1065: open("/usr/lib/passwdutil.so.1", O_RDONLY) = 3
1065: stat64("/lib/libc.so.1", 0xFFBFEDE0) = 0
1065: resolvepath("/lib/libc.so.1", "/lib/libc.so.1", 1023) = 14
1065: open("/lib/libc.so.1", O_RDONLY) = 3
1065: stat64("/lib/libnsl.so.1", 0xFFBFEDE0) = 0
1065: resolvepath("/lib/libnsl.so.1", "/lib/libnsl.so.1", 1023) = 16
1065: open("/lib/libnsl.so.1", O_RDONLY) = 3
1065: stat64("/lib/libcmd.so.1", 0xFFBFEDE0) = 0
1065: resolvepath("/lib/libcmd.so.1", "/lib/libcmd.so.1", 1023) = 16
1065: open("/lib/libcmd.so.1", O_RDONLY) = 3
1065: getcontext(0xFFBFF4F0)
1065: getrlimit(RLIMIT_STACK, 0xFFBFF4D0) = 0
1065: getpid() = 1065 [1064]
1065: setustack(0xFF362A88)
1065: sigfillset(0xFF31B3BC) = 0
1065: stat64("/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1", 0xFFBFE980) = 0
1065: resolvepath("/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1", "/platform/sun4v/lib/libc_psr.so.1", 1023) = 33
1065: open("/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1", O_RDONLY) = 3
1065: time() = 1384439953
1065: open("/var/run/tzsync", O_RDONLY) = 3
1065: open("/usr/share/lib/zoneinfo/US/Eastern", O_RDONLY) = 3
1065: fstat64(3, 0xFFBFF4A0) = 0
1065: read(3, " T Z i f\0\0\0\0\0\0\0\0".., 1267) = 1267
1065: creat("/etc/.pwd.lock", 0600) = 3
1065: fcntl(3, F_SETLK, 0xFF3159D0) = 0
1065: getpid() = 1065 [1064]
1065: stat64("/lib/libsldap.so.1", 0xFFBFE980) Err#2 ENOENT
1065: stat64("/usr/lib/libsldap.so.1", 0xFFBFE980) = 0
1065: resolvepath("/usr/lib/libsldap.so.1", "/usr/lib/libsldap.so.1", 1023) = 22
1065: open("/usr/lib/libsldap.so.1", O_RDONLY) = 4
1065: stat64("/lib/libldap.so.5", 0xFFBFE8A0) Err#2 ENOENT
1065: stat64("/usr/lib/libldap.so.5", 0xFFBFE8A0) = 0
1065: resolvepath("/usr/lib/libldap.so.5", "/usr/lib/libldap.so.5", 1023) = 21
1065: open("/usr/lib/libldap.so.5", O_RDONLY) = 4
1065: stat64("/lib/libscf.so.1", 0xFFBFE8A0) = 0
1065: resolvepath("/lib/libscf.so.1", "/lib/libscf.so.1", 1023) = 16
1065: open("/lib/libscf.so.1", O_RDONLY) = 4
1065: stat64("/lib/libdoor.so.1", 0xFFBFE8A0) = 0
1065: resolvepath("/lib/libdoor.so.1", "/lib/libdoor.so.1", 1023) = 17
1065: open("/lib/libdoor.so.1", O_RDONLY) = 4
1065: stat64("/usr/lib/mps/libc.so.1", 0xFFBFE8A0) Err#2 ENOENT
1065: stat64("/lib/libuutil.so.1", 0xFFBFE8A0) = 0
1065: resolvepath("/lib/libuutil.so.1", "/lib/libuutil.so.1", 1023) = 18
1065: open("/lib/libuutil.so.1", O_RDONLY) = 4
1065: stat64("/lib/libgen.so.1", 0xFFBFE8A0) = 0
1065: resolvepath("/lib/libgen.so.1", "/lib/libgen.so.1", 1023) = 16
1065: open("/lib/libgen.so.1", O_RDONLY) = 4
1065: stat64("/usr/lib/mps/libsocket.so.1", 0xFFBFE598) Err#2 ENOENT
1065: stat64("/lib/libsocket.so.1", 0xFFBFE598) = 0
1065: resolvepath("/lib/libsocket.so.1", "/lib/libsocket.so.1", 1023) = 19
1065: open("/lib/libsocket.so.1", O_RDONLY) = 4
1065: stat64("/usr/lib/mps/libnsl.so.1", 0xFFBFE598) Err#2 ENOENT
1065: stat64("/lib/libmp.so.2", 0xFFBFE980) = 0
1065: resolvepath("/lib/libmp.so.2", "/lib/libmp.so.2", 1023) = 15
1065: open("/lib/libmp.so.2", O_RDONLY) = 4
1065: stat64("/lib/libmd.so.1", 0xFFBFE980) = 0
1065: resolvepath("/lib/libmd.so.1", "/lib/libmd.so.1", 1023) = 15
1065: open("/lib/libmd.so.1", O_RDONLY) = 4
1065: stat64("/usr/lib/mps/libsasl.so.1", 0xFFBFE980) Err#2 ENOENT
1065: stat64("/lib/libsasl.so.1", 0xFFBFE980) Err#2 ENOENT
1065: stat64("/usr/lib/libsasl.so.1", 0xFFBFE980) = 0
1065: resolvepath("/usr/lib/libsasl.so.1", "/usr/lib/libsasl.so.1", 1023) = 21
1065: open("/usr/lib/libsasl.so.1", O_RDONLY) = 4
1065: stat64("/platform/SUNW,Sun-Fire-T200/lib/libmd_psr.so.1", 0xFFBFE4C8) = 0
1065: resolvepath("/platform/SUNW,Sun-Fire-T200/lib/libmd_psr.so.1", "/platform/sun4v/lib/libmd_psr.so.1", 1023) = 34
1065: open("/platform/SUNW,Sun-Fire-T200/lib/libmd_psr.so.1", O_RDONLY) = 4
1065: stat64("/usr/lib/mps/libmd.so.1", 0xFFBFE980) Err#2 ENOENT
1065: stat64("/usr/lib/mps/libnspr4.so", 0xFFBFE980) = 0
1065: resolvepath("/usr/lib/mps/libnspr4.so", "/usr/lib/mps/libnspr4.so", 1023) = 24
1065: open("/usr/lib/mps/libnspr4.so", O_RDONLY) = 4
1065: stat64("/lib/libpthread.so.1", 0xFFBFE8A0) = 0
1065: resolvepath("/lib/libpthread.so.1", "/lib/libpthread.so.1", 1023) = 20
1065: open("/lib/libpthread.so.1", O_RDONLY) = 4
1065: stat64("/lib/librt.so.1", 0xFFBFE8A0) = 0
1065: resolvepath("/lib/librt.so.1", "/lib/librt.so.1", 1023) = 15
1065: open("/lib/librt.so.1", O_RDONLY) = 4
1065: stat64("/lib/libdl.so.1", 0xFFBFE8A0) = 0
1065: resolvepath("/lib/libdl.so.1", "/lib/libdl.so.1", 1023) = 15
1065: open("/lib/libdl.so.1", O_RDONLY) = 4
1065: stat64("/lib/libaio.so.1", 0xFFBFE8A0) = 0
1065: resolvepath("/lib/libaio.so.1", "/lib/libaio.so.1", 1023) = 16
1065: open("/lib/libaio.so.1", O_RDONLY) = 4
1065: sysinfo(SI_ISALIST, "sparcv9 sparcv8plus sparcv8 sparcv8-fsmuld sparcv7 sparc sparcv9+vis sparcv9+vis2 sparcv8plus+vis sparcv8plus+vis2", 257) = 115
1065: stat64("/usr/lib/mps/cpu/sparcv9/libnspr_flt4.so", 0xFFBFE4C8) Err#2 ENOENT
1065: stat64("/usr/lib/mps/cpu/sparcv8plus/libnspr_flt4.so", 0xFFBFE4C8) = 0
1065: resolvepath("/usr/lib/mps/cpu/sparcv8plus/libnspr_flt4.so", "/usr/lib/mps/cpu/sparcv8plus/libnspr_flt4.so", 1023) = 44
1065: open("/usr/lib/mps/cpu/sparcv8plus/libnspr_flt4.so", O_RDONLY) = 4
1065: stat64("/usr/lib/mps/libplc4.so", 0xFFBFE980) = 0
1065: resolvepath("/usr/lib/mps/libplc4.so", "/usr/lib/mps/libplc4.so", 1023) = 23
1065: open("/usr/lib/mps/libplc4.so", O_RDONLY) = 4
1065: stat64("/usr/lib/mps/libnss3.so", 0xFFBFE980) = 0
1065: resolvepath("/usr/lib/mps/libnss3.so", "/usr/lib/mps/libnss3.so", 1023) = 23
1065: open("/usr/lib/mps/libnss3.so", O_RDONLY) = 4
1065: stat64("/usr/lib/mps/libnssutil3.so", 0xFFBFE8A0) = 0
1065: resolvepath("/usr/lib/mps/libnssutil3.so", "/usr/lib/mps/libnssutil3.so", 1023) = 27
1065: open("/usr/lib/mps/libnssutil3.so", O_RDONLY) = 4
1065: stat64("/usr/lib/mps/libplds4.so", 0xFFBFE8A0) = 0
1065: resolvepath("/usr/lib/mps/libplds4.so", "/usr/lib/mps/libplds4.so", 1023) = 24
1065: open("/usr/lib/mps/libplds4.so", O_RDONLY) = 4
1065: stat64("/usr/lib/mps/secv1/libc.so.1", 0xFFBFE8A0) Err#2 ENOENT
1065: stat64("/usr/lib/mps/libssl3.so", 0xFFBFE980) = 0
1065: resolvepath("/usr/lib/mps/libssl3.so", "/usr/lib/mps/libssl3.so", 1023) = 23
1065: open("/usr/lib/mps/libssl3.so", O_RDONLY) = 4
1065: stat64("/usr/lib/mps/libthread.so.1", 0xFFBFE8A0) Err#2 ENOENT
1065: stat64("/usr/lib/mps/secv1/libthread.so.1", 0xFFBFE8A0) Err#2 ENOENT
1065: stat64("/lib/libthread.so.1", 0xFFBFE8A0) = 0
1065: resolvepath("/lib/libthread.so.1", "/lib/libthread.so.1", 1023) = 19
1065: open("/lib/libthread.so.1", O_RDONLY) = 4
1065: stat64("/usr/lib/mps/librt.so.1", 0xFFBFE8A0) Err#2 ENOENT
1065: stat64("/usr/lib/mps/secv1/librt.so.1", 0xFFBFE8A0) Err#2 ENOENT
1065: write(2, " l d . s o . 1 : p a s".., 130) = 130
1065: write(2, "\n", 1) = 1
1065: lwp_self() = 1
1064: waitid(P_ALL, 0, 0xFFBFE980, WEXITED|WTRAPPED) = 0
1064: _exit(0)
# ldd /usr/sbin/passmgmt /usr/lib/passwdutil.so.1
/usr/sbin/passmgmt:
libsecdb.so.1 => /lib/libsecdb.so.1
passwdutil.so.1 => /usr/lib/passwdutil.so.1
libc.so.1 => /lib/libc.so.1
libnsl.so.1 => /lib/libnsl.so.1
libcmd.so.1 => /lib/libcmd.so.1
libsldap.so.1 => /usr/lib/libsldap.so.1
libmp.so.2 => /lib/libmp.so.2
libmd.so.1 => /lib/libmd.so.1
libscf.so.1 => /lib/libscf.so.1
libldap.so.5 => /usr/lib/libldap.so.5
libdoor.so.1 => /lib/libdoor.so.1
libuutil.so.1 => /lib/libuutil.so.1
libgen.so.1 => /lib/libgen.so.1
libsasl.so.1 => /usr/lib/libsasl.so.1
libsocket.so.1 => /lib/libsocket.so.1
libnspr4.so => /usr/lib/mps/libnspr4.so
libplc4.so => /usr/lib/mps/libplc4.so
libnss3.so => /usr/lib/mps/libnss3.so
libssl3.so => /usr/lib/mps/libssl3.so
libpthread.so.1 => /lib/libpthread.so.1
librt.so.1 => /lib/librt.so.1
libdl.so.1 => /lib/libdl.so.1
libnssutil3.so => /usr/lib/mps/libnssutil3.so
libplds4.so => /usr/lib/mps/libplds4.so
libthread.so.1 => /lib/libthread.so.1
libaio.so.1 => /lib/libaio.so.1
libm.so.2 => /lib/libm.so.2
/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1
/platform/SUNW,Sun-Fire-T200/lib/libmd_psr.so.1
/usr/lib/mps/cpu/sparcv8plus/libnspr_flt4.so
/usr/lib/passwdutil.so.1:
libcmd.so.1 => /lib/libcmd.so.1
libsldap.so.1 => /usr/lib/libsldap.so.1
libnsl.so.1 => /lib/libnsl.so.1
libc.so.1 => /lib/libc.so.1
libldap.so.5 => /usr/lib/libldap.so.5
libscf.so.1 => /lib/libscf.so.1
libdoor.so.1 => /lib/libdoor.so.1
libmp.so.2 => /lib/libmp.so.2
libmd.so.1 => /lib/libmd.so.1
libsasl.so.1 => /usr/lib/libsasl.so.1
libsocket.so.1 => /lib/libsocket.so.1
libnspr4.so => /usr/lib/mps/libnspr4.so
libplc4.so => /usr/lib/mps/libplc4.so
libnss3.so => /usr/lib/mps/libnss3.so
libssl3.so => /usr/lib/mps/libssl3.so
libuutil.so.1 => /lib/libuutil.so.1
libgen.so.1 => /lib/libgen.so.1
libpthread.so.1 => /lib/libpthread.so.1
librt.so.1 => /lib/librt.so.1
libdl.so.1 => /lib/libdl.so.1
libnssutil3.so => /usr/lib/mps/libnssutil3.so
libplds4.so => /usr/lib/mps/libplds4.so
libthread.so.1 => /lib/libthread.so.1
libaio.so.1 => /lib/libaio.so.1
libm.so.2 => /lib/libm.so.2
/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1
/platform/SUNW,Sun-Fire-T200/lib/libmd_psr.so.1
/usr/lib/mps/cpu/sparcv8plus/libnspr_flt4.so
# pkgchk SUNWtls1
WARNING: no pathnames were associated with <SUNWtls1>
# set|grep LD;crle;truss -w2 -ft open useradd -s /bin/bash -d /home/testuser -m testuser
Configuration file [version 4]: /var/ld/ld.config
Platform: 32-bit MSB SPARC
Default Library Path (ELF): /lib:/usr/lib:/usr/sfw/lib
Trusted Directories (ELF): /lib/secure:/usr/lib/secure (system default)
Command line:
crle -c /var/ld/ld.config -l /lib:/usr/lib:/usr/sfw/lib
922: open("/var/ld/ld.config", O_RDONLY) = 3
922: open("/lib/libsecdb.so.1", O_RDONLY) = 3
922: open("/usr/lib/libproject.so.1", O_RDONLY) = 3
922: open("/lib/libc.so.1", O_RDONLY) = 3
922: open("/lib/libnsl.so.1", O_RDONLY) = 3
922: open("/lib/libcmd.so.1", O_RDONLY) = 3
922: open("/lib/libproc.so.1", O_RDONLY) = 3
922: open("/lib/librtld_db.so.1", O_RDONLY) = 3
922: open("/lib/libelf.so.1", O_RDONLY) = 3
922: open("/lib/libctf.so.1", O_RDONLY) = 3
922: open("/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1", O_RDONLY) = 3
922: open("/usr/sadm/defadduser", O_RDONLY) = 3
922: open("/proc/922/psinfo", O_RDONLY) = 3
922: open64("/var/run/name_service_door", O_RDONLY) = 3
923: open("/dev/null", O_RDWR|O_CREAT|O_TRUNC, 0666) = 1
923: open("/dev/null", O_RDWR|O_CREAT|O_TRUNC, 0666) = 2
923: open("/var/ld/ld.config", O_RDONLY) = 3
923: open("/lib/libsecdb.so.1", O_RDONLY) = 3
923: open("/usr/lib/passwdutil.so.1", O_RDONLY) = 3
923: open("/lib/libc.so.1", O_RDONLY) = 3
923: open("/lib/libnsl.so.1", O_RDONLY) = 3
923: open("/lib/libcmd.so.1", O_RDONLY) = 3
923: open("/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1", O_RDONLY) = 3
923: open("/var/run/tzsync", O_RDONLY) = 3
923: open("/usr/share/lib/zoneinfo/US/Eastern", O_RDONLY) = 3
923: open("/usr/lib/libsldap.so.1", O_RDONLY) = 4
923: open("/usr/lib/libldap.so.5", O_RDONLY) = 4
923: open("/lib/libscf.so.1", O_RDONLY) = 4
923: open("/lib/libdoor.so.1", O_RDONLY) = 4
923: open("/lib/libuutil.so.1", O_RDONLY) = 4
923: open("/lib/libgen.so.1", O_RDONLY) = 4
923: open("/lib/libsocket.so.1", O_RDONLY) = 4
923: open("/lib/libmp.so.2", O_RDONLY) = 4
923: open("/lib/libmd.so.1", O_RDONLY) = 4
923: open("/usr/lib/libsasl.so.1", O_RDONLY) = 4
923: open("/platform/SUNW,Sun-Fire-T200/lib/libmd_psr.so.1", O_RDONLY) = 4
923: open("/usr/lib/mps/libnspr4.so", O_RDONLY) = 4
923: open("/lib/libpthread.so.1", O_RDONLY) = 4
923: open("/lib/librt.so.1", O_RDONLY) = 4
923: open("/lib/libdl.so.1", O_RDONLY) = 4
923: open("/lib/libaio.so.1", O_RDONLY) = 4
923: open("/usr/lib/mps/cpu/sparcv8plus/libnspr_flt4.so", O_RDONLY) = 4
923: open("/usr/lib/mps/libplc4.so", O_RDONLY) = 4
923: open("/usr/lib/mps/libnss3.so", O_RDONLY) = 4
923: open("/usr/lib/mps/libnssutil3.so", O_RDONLY) = 4
923: open("/usr/lib/mps/libplds4.so", O_RDONLY) = 4
923: open("/usr/lib/mps/libssl3.so", O_RDONLY) = 4
923: open("/lib/libthread.so.1", O_RDONLY) = 4
923: write(2, 0xFF3FC74C, 130) = 130
923: l d . s o . 1 : p a s s m g m t : f a t a l : r e l o c a
923: t i o n e r r o r : f i l e / u s r / s b i n / p a s s m
923: g m t : s y m b o l _ _ p w u _ l o c k i n g _ r e s t r i
923: c t i v e : r e f e r e n c e d s y m b o l n o t f o u
923: n d
923: write(2, "\n", 1) = 1
925: open("/var/ld/ld.config", O_RDONLY) = 3
925: open("/lib/libc.so.1", O_RDONLY) = 3
925: open("/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1", O_RDONLY) = 3
925: open("/lib/libsec.so.1", O_RDONLY) = 3
925: open("/lib/libavl.so.1", O_RDONLY) = 3
925: open("/lib/libcmdutils.so.1", O_RDONLY) = 3
925: open64("/etc/skel/.profile", O_RDONLY) = 4
925: open64("/etc/skel/local.cshrc", O_RDONLY) = 4
925: open64("/etc/skel/local.login", O_RDONLY) = 4
925: open64("/etc/skel/local.profile", O_RDONLY) = 4
927: open("/var/ld/ld.config", O_RDONLY) = 3
927: open("/lib/libcmdutils.so.1", O_RDONLY) = 3
927: open("/lib/libc.so.1", O_RDONLY) = 3
927: open("/lib/libavl.so.1", O_RDONLY) = 3
927: open("/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1", O_RDONLY) = 3
#
# passmgmt
ld.so.1: passmgmt: fatal: relocation error: file /usr/sbin/passmgmt: symbol __pwu_locking_restrictive: referenced symbol not found
Killed
#
# pkgchk SUNWcsl SUNWcslr SUNWdpl SUNWlibms SUNWlibmsr SUNWlibsasl SUNWpr SUNWtls
WARNING: no pathnames were associated with <SUNWdpl>
# ldd -dp /usr/bin/passmgmt
libsecdb.so.1 => /lib/libsecdb.so.1
passwdutil.so.1 => /usr/lib/passwdutil.so.1
libc.so.1 => /lib/libc.so.1
libnsl.so.1 => /lib/libnsl.so.1
libcmd.so.1 => /lib/libcmd.so.1
libsldap.so.1 => /usr/lib/libsldap.so.1
libmp.so.2 => /lib/libmp.so.2
libmd.so.1 => /lib/libmd.so.1
libscf.so.1 => /lib/libscf.so.1
libldap.so.5 => /usr/lib/libldap.so.5
libdoor.so.1 => /lib/libdoor.so.1
libuutil.so.1 => /lib/libuutil.so.1
libgen.so.1 => /lib/libgen.so.1
libsasl.so.1 => /usr/lib/libsasl.so.1
libsocket.so.1 => /lib/libsocket.so.1
libnspr4.so => /usr/lib/mps/libnspr4.so
libplc4.so => /usr/lib/mps/libplc4.so
libnss3.so => /usr/lib/mps/libnss3.so
libssl3.so => /usr/lib/mps/libssl3.so
libpthread.so.1 => /lib/libpthread.so.1
librt.so.1 => /lib/librt.so.1
libdl.so.1 => /lib/libdl.so.1
libnssutil3.so => /usr/lib/mps/libnssutil3.so
libplds4.so => /usr/lib/mps/libplds4.so
libthread.so.1 => /lib/libthread.so.1
libaio.so.1 => /lib/libaio.so.1
libm.so.2 => /lib/libm.so.2
/platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1
/platform/SUNW,Sun-Fire-T200/lib/libmd_psr.so.1
/usr/lib/mps/cpu/sparcv8plus/libnspr_flt4.so
후속 조치: 몇 주 후에 문제를 해결하기 위해 OS를 다시 설치했습니다.
답변1
당신이 관찰하고 있는 것처럼 보이는 것은 확실히 예상된 동작이 아닙니다.
나는 당신이 useradd
표준 오류 및 명령 상태를 버리는 실제 래퍼라고 생각합니다.
이는 다음 명령을 사용하여 확인할 수 있습니다.
type useradd
useradd가 Solaris에서 실패하는 일반적인 이유는 홈 자동 마운트가 이 -m
옵션을 사용할 수 없기 때문입니다.
이것은 작동합니다:
useradd -s /bin/bash -d /export/home/testuser -m testuser
추신: #
루트 프롬프트를 사용하는 것은 확립된 규칙입니다. 특히 게시할 때 이를 따르지 않으면 매우 혼란스러울 수 있습니다.
고쳐 쓰다:
확인해야 할 몇 가지 사항이 있습니다.
1: LDAP 구성이 손상된 것 같습니다. 어떤 이유로 로더가 더 이상 libthread 및 librt와 같은 라이브러리를 로드하기 위해 표준 디렉터리를 찾지 않습니다. ldap
다음 비밀번호 항목을 제거하여 최소한 일시적으로 LDAP를 비활성화해 보십시오 /etc/nsswitch.conf
.
passwd: files
그런 다음 사용자를 다시 생성해 보십시오.
3: useradd
그래도 실패하면 pam 구성 파일( /etc/pam.conf
)을 다른 서버의 구성 파일과 비교하여 차이점이 있는지 확인하세요.
4: 그것도 실패한다면 라이브러리와 호환되지 않는 것을 설치했거나 Solaris 패치를 놓친 것 같습니다.