#configuration
21 one-liners with this tag.
All one-liners tagged configuration
Change service settings with an override
#systemctl edit mariadb
Check the Apache configuration for syntax errors
#apache2ctl configtest
Check the current value of a PHP setting
$php -i | grep -i memory_limit
Check the nginx configuration for syntax errors
#nginx -t
Find modified package configuration files
#debsums -ce
List all configuration files Apache loads
#apache2ctl -t -D DUMP_INCLUDES
List loaded Apache modules
#apache2ctl -M
Permanently limit the size of the systemd journal
#mkdir -p /etc/systemd/journald.conf.d && printf '[Journal]\nSystemMaxUse=500M\n' > /etc/systemd/journald.conf.d/size.conf && systemctl restart systemd-journald
Replace text in a file with sed and keep a backup
$sed -i.bak 's|memory_limit = 128M|memory_limit = 256M|g' php.ini
Show a config file without comments and blank lines
$grep -Ev '^\s*(#|;|$)' /etc/php/8.2/fpm/php.ini
Show a service's unit file including overrides
$systemctl cat mariadb
Show all Apache virtual hosts and their config files
#apache2ctl -S
Show all nginx server_name entries with their config file
#nginx -T 2>/dev/null | grep -E "^# configuration file|server_name "
Show custom Plesk settings in panel.ini
#cat /usr/local/psa/admin/conf/panel.ini
Show the additional nginx directives of a Plesk domain
#cat /var/www/vhosts/system/example.com/conf/vhost_nginx.conf
Show the effective sshd settings
#sshd -T | grep -Ei '^(port|permitrootlogin|passwordauthentication|pubkeyauthentication|kbdinteractiveauthentication|allowusers|maxauthtries) '
Show the environment variables of a Docker container
#docker exec app env
Show the loaded php.ini files
$php --ini
Show the nginx configuration Plesk generated for a domain
#cat /var/www/vhosts/system/example.com/conf/nginx.conf
Test a logrotate configuration without rotating
#logrotate -d /etc/logrotate.d/nginx
Test the sshd config and reload the SSH service
#sshd -t && systemctl reload ssh