[20211115]配置logrotate提示parent directory has insecure permissions.txt
[20211115]配置logrotate提示parent directory has insecure permissions.txt
--//今天在配置logrotate遇到一些問題,做一個記錄。
# /usr/sbin/logrotate -d /etc/logrotate.d/oracle
rotating pattern: /u01/app/oracle/product/11.2.0.3/db_1/network/log/listener.log weekly (5 rotations)
empty log files are not rotated, old logs are removed
considering log /u01/app/oracle/product/11.2.0.3/db_1/network/log/listener.log
error: skipping "/u01/app/oracle/product/11.2.0.3/db_1/network/log/listener.log" because parent directory has insecure
permissions (It's world writable or writable by group which is not "root") Set "su" directive in config file to tell
logrotate which user/group should be used for rotation.
--//我開始以為是某個目錄許可權問題,上網查詢,加入如下內容,問題解決。
su oracle oinstall
--//也可以加入如下。
su root root
--//我在想如何順序查詢目錄的許可權呢?簡單寫一行命令如下:
# cd / ;echo /u01/app/oracle/product/11.2.0.3/db_1/network/log | sed 's+/+\n+g' | xargs -IQ echo "ls -ld Q;cd Q" | bash
drwxr-xr-x. 4 root root 31 Feb 3 2021 u01
drwxr-xr-x. 5 root root 51 Aug 17 16:56 app
drwxrwxr-x. 10 oracle oinstall 143 May 19 09:02 oracle
drwxr-xr-x. 4 oracle oinstall 36 May 17 18:15 product
drwxr-xr-x. 3 oracle oinstall 18 May 17 18:15 11.2.0.3
drwxr-xr-x. 73 oracle oinstall 4096 Nov 2 09:37 db_1
drwxr-xr-x. 11 oracle oinstall 117 May 17 18:23 network
drwxrwx---. 2 oracle oinstall 26 Nov 15 08:47 log
--//這樣就可以順序看到各個目錄的許可權。
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/267265/viewspace-2842141/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 使用logrotate配置日誌輪詢logrotate
- 消除Warning: Using a password on the command line interface can be insecure的提示
- nginx1.24配置logrotate日誌切割Nginxlogrotate
- settings.xml has syntax errors less...Parent org.springframework.boot:spring-boot-starter-已解決XMLErrorSpringFrameworkboot
- Linux中編譯或安裝程式時提示No such file or directoryLinux編譯
- window.parent
- springboot配置sql提示Spring BootSQL
- dbeaver 升級 24.1.x 版本提示 An error has occurred 的解決Error
- 解決問題:啟動不了VM,提示 Your VM has become “inaccessible…
- 日誌切分神器--logrotatelogrotate
- DVWA靶場實戰(六)——Insecure CAPTCHAAPT
- Spring系列第十三講 使用繼承簡化bean配置(abstract & parent)Spring繼承Bean
- mac 下vscode 更新時提示:Could not create temporary directory: 許可權被拒絕MacVSCode
- linux輸入yum後提示: -bash: /usr/bin/yum: No such file or directory的解決方案Linux
- windows10系統使用印表機提示Active directory怎麼解決Windows
- Flutter框架分析- Parent DataFlutter框架
- multi-parent genetic algorithmsGo
- 理解spring-boot-starter-parentSpringboot
- 【已解決】挖礦病毒 logrotate 185.196.8.123logrotate
- [CSS 3] :has()CSS
- [20211115]12c以上版本Last Login Time 引發的故障.txtAST
- Bad magic number for central directory
- Flume - [02] Spooling Directory Source
- The directory xx is registered as a Git rootGit
- RuntimeError: An attempt has been made to start a new process before the current process hasError
- 如何使用 logrotate 命令保持日誌檔案更新logrotate
- yarn certificate has expiredYarn
- Reflect.has() 方法
- 如何處理Docker錯誤訊息:please add——insecure-registryDocker
- 全面掌握Directory.Build.propsUI
- docker容器掛載 No such file or directoryDocker
- [20210622]logrotate清除oracle aud檔案的問題.txtlogrotateOracle
- babel webpack vue 配置檔案支援智慧提示BabelWebVue
- Laravel 54 配置 Elasticsearch 時的報錯提示LaravelElasticsearch
- MySQL server has gone awayMySqlServerGo
- ‘dict‘ object has no attribute ‘iteritems‘Object
- Proxy handler.has() 方法
- Process object has no attribute '_popen'Object