locate /bin/ls
warning: locate: could not open database: /var/lib/slocate/slocate.db: No such file or directory
warning: You need to run the 'updatedb' command (as root) to create the database.
Please have a look at /etc/updatedb.conf to enable the daily cron job.
这是提示我们,系统目前没有创建slocate 数据库。
解决办法: 输入命令 updatedb 创建数据库
然后需 vim /etc/updatedb.conf
让 DAILY_UPDATE=yes
warning: locate: could not open database: /var/lib/slocate/slocate.db: No such file or directory
warning: You need to run the 'updatedb' command (as root) to create the database.
Please have a look at /etc/updatedb.conf to enable the daily cron job.
这是提示我们,系统目前没有创建slocate 数据库。
解决办法: 输入命令 updatedb 创建数据库
然后需 vim /etc/updatedb.conf
让 DAILY_UPDATE=yes
0
vim /etc/updatedb.conf 显示的信息如下,并没有老师说的 DAILY_UPDATE
PRUNE_BIND_MOUNTS = "yes"
PRUNEFS = "9p afs anon_inodefs auto autofs bdev binfmt_misc cgroup cifs coda configfs cpuset debugfs devpts ecryptfs exofs fuse fusectl gfs gfs2 hugetlbfs inotifyfs iso9660 jffs2 lustre mqueue ncpfs nfs nfs4 nfsd pipefs proc ramfs rootfs rpc_pipefs securityfs selinuxfs sfs sockfs sysfs tmpfs ubifs udf usbfs vmhgfs"
PRUNENAMES = ".git .hg .svn"
PRUNEPATHS = "/afs /media /net /sfs /tmp /udev /var/cache/ccache /var/spool/cups /var/spool/squid /var/tmp"
编辑回复