今天發現一個很有趣的東西,Linux系統中有一個文件的屬主是數字
~~~
[root@rac1 ~]# ls -al test
-rw-r--r-- 1 111 root 0 Sep 10 04:13 test
~~~
很好奇,想了想,可能是改變屬組的時候使用的uid,但是后來uid改變了,然后就嘗試一下:
~~~
[root@rac1 ~]# touch test
[root@rac1 ~]# useradd -u 112 -g root test
[root@rac1 ~]# chown 112:root test
[root@rac1 ~]# ls -al test
-rw-r--r-- 1 lm root 0 Sep 10 04:18 test
[root@rac1 ~]# usermod -u 113 -g root test
[root@rac1 ~]# ls -al test
-rw-r--r-- 1 112 root 0 Sep 10 04:18 test
~~~
現在,數字的屬主就出現了。