Cronで、MySQLのSQLクエリを定期的に実行する

MySQLのDBのメンテンナンスで定期的にupdate, delete分を実行したい場合があります。
そのようなケースではMySQLのSQL文を実行するシェルスクリプト ...
CentOS Stream 9のCockpitで、Let’s EncryptのSSL証明書を利用する

以前のCentOS Stream 9では、SSL証明書と ...
複数のファイルで実行権限があるかないかをチェックする方法

Cronでシェルスクリプトを実行する設定をしていましたは、指定した時間になっても実行されていませんでした。原因調査するとCronで実行するシェルスクリプトに実行権限が付与するのを忘れていたようです
シェルスクリプトは特定の ...
MailBoxに溜まったメールをmailコマンドで削除する

Cron等の通知メールやシステム関連のメールがユーザーやroot宛のMailboxに大量に溜まっているサーバーがありました。
普段は下記のようなコマンドをcronで設定してメールを削除しています
# cat/dev/ ...mailコマンドでメールが読めない

ディスクの容量が圧迫したので容量削減が多いファイルを探していたのですが、「Mailbox」の容量が大きいので受診したメールを削除しようと思い、メールコマンドを入力しても下記のように「No mail for 」が表示されメールが読めませ ...
特定のIPアドレスのみWordPress管理画面にアクセスを許可する方法

WordPressのセキュリティ対策で管理画面へアクセスは、特定のIPアドレスのみアクセスできるように設定していますが、WordPressの ...
無償SSL署名書(Let’s Encrypt)で自動更新で失敗

無償SSL署名書のLet’s Encryptで自動更新で失敗していました。ログを確認すると以下のようなエラーとなっていました
$ sudo view/var/log/letsencrypt/letsencrypt.l ...NextCloudアップデート失敗の原因と解決方法(ダウンロードで止まる)

NextCloudのバージョンアップ通知が来たので、NextCloudのサーバー側をアップデートすると通常なら数分で終わるはずがダウンロードの手順です ...
rsyncコマンドで特定のディレクトリを除外してコピーする

scpコマンドで特定のディレクトリを除外してコピーしたい場合、scpコマンドでは直接そのような機能がないようです。
scpコマンドの代わりにrsyncコマンドを使用して特定のディレクトリを除外してディレクトリをコピーします。r ...
cerbot renewを個別のドメインのみ発行する方法

通常、「certbot renew」を実行すると、SSL証明書を発行している全てのドメインの証明書が更新されます。
しかし、自動更新時に特定のドメインのみが失敗し、そのドメイ ...
無料SSL証明書(Let’s Encrypt)の自動更新でエラーログ

Zabbixで「/var/log/messages」のログ監視をしていますが、以下のエラーが出ていました
Jun 13 00:56:37 WEB01 systemd: Failed to start This service a ...dnf コマンドで「 rpmdb: BDB0113~BDB1507 Thread died in Berkeley DB library」のエラー

dnfコマンドでパッケージのアップデートを実施しようとすると下記のエラーが発生しました
# RPMデータベース (rpmdb) が壊れてdnf コマンドでエラーとなる$ sudo dnf updateerror: rpmdb: ...Nextcloudでログのパラメータ変更(occコマンド)

Nextcloudでログ関係のパラメータを変更します。Nextcloudをアップデートして管理画面にログインするとログファイルにWARNINGが上がっていたりして警告が表示されるケースが多くなってきたのでロ ...
vsftpdでFTPS接続をできるように設定する

vsftpdでFTPS接続が必要になりFTPS接続できるように設定を追加しました。
FTP接続では制御用コネクションと ...
Nextcloudのログの場所

Nextcloudの管理画面にログインするとログファイルに過去のエラーがあるとの警告がでるケースが多くなってきました。過去の分で修正しているので気にしなくてもいいですが、Nextcloudのログファイルはどこにあるのか気になったの調べ ...