chirale

IT and beyond

To disallow password authentication on ssh, adduser –disabled-password will not disable openSSH password. To disable the password authentication, you have to put these values on /etc/ssh/sshd_config to: PasswordAuthentication no UsePAM no PermitRootLogin no Then you’ve to: to apply changes. Connection will not be reset so before logout try to login on a different terminal to …

Continue reading

After a failed restart of the nginx server, you can get this error typing journalctl -xe: nginx: [emerg] open() “/usr/share/nginx/off” failed (13: Permission denied) [SOLVED] This is caused by a misconfiguration of nginx.conf or a conf inside the /etc/nginx/conf.d/ directory where there’s something like: This is the wrong way to disable logs. Nginx is actually …

Continue reading

mdadm is the utility to check and report failures on RAID disks. The usual way this Linux application send its message is a plain old e-mail. In this howto you’ll find the instruction to use an external mail server with mdadm. First, replace sendmail with an external email account. After you’ve configured and tested msmtp …

Continue reading

To use an external SMTP for all system e-mails, you have to install these: Where msmtp-mta transform the external reference in the sendmail command usable by any application using sendmail. In this way you haven’t to install and configure Postfix since you’ll rely on an external SMTP service. Create the config file for msmtp This …

Continue reading

With the General Data Protection Regulation (GDPR) enforced by European Union logs have to be cleaned regularly to delete IP addresses and other information about visitors. This can be interpreted as a way to protect an emerging and discussed right, the right to be forgotten. This new regulation is impacting every automated log system out …

Continue reading

To delete git files uploaded accidentally to GitHub (or any other public repository) do these steps: Download https://rtyley.github.io/bfg-repo-cleaner/ as suggested by GitHub git clone –mirror GIT_REPOSITORY_URL cd path/to/cloned/repository Download BFG java -jar /path/to/download/dir/bfg-VERSION.jar –delete-files filename.ext Run the command specified by BFG (usually git reflog expire –expire=now –all && git gc –prune=now –aggressive) git push If …

Continue reading