Not able to upgrade Ubuntu release

With the release of Ubuntu 20.02 LTS (Focal Fossa) my current Ubuntu server running 19.04 Disco Dingo did not receive updates anymore – Time to upgrade.So I connected to my server using SSH and entered the command which failed with the error: Failed to connect to https://changelogs.ubuntu.com/meta-release. Check your Internet connection Weiterlesen…

Nextcloud Gmail

Cannot send email using Gmail account in Nextcloud 20: Change in file: /var/www/nextcloud/3rdparty/swiftmailer/swiftmailer/lib/classes/Swift/Transport/StreamBuffer.php line number 272 from $this->stream = @stream_socket_client($host.‘:‘.$this->params[‚port‘], $errno, $errstr, $timeout, STREAM_CLIENT_CONNECT, $streamContext);              to $this->stream = @stream_socket_client($host.‘:‘.$this->params[‚port‘], $errno, $errstr, $timeout, STREAM_CLIENT_CONNECT, stream_context_create(array(’ssl’=>[‚verify_peer’=>false, ‚verify_peer_name’=>false, ‚allow_self_signed’=>true])));

PHP 7.2 (APCU)

https://janw.me/2017/installing-php7-2-rapsberry-pi/ https://stackoverflow.com/questions/47800957/apcu-is-not-enabled-when-installed-with-apt-get-on-php7-2-apache-stretch-image https://serverpilot.io/docs/how-to-install-the-php-apcu-extension add extension=apcu.so to /etc/php/7.2/mods-available/apcu.ini Extensions are loaded when the appropriate symlink is placed in /etc/php/7.2/fpm/conf.d/ with eg. ln -s /etc/php/7.2/mods-available/apcu.ini /etc/php/7.2/fpm/conf.d/20-apcu.ini So it is not necessary to add the line extension=apcu.so to any php.ini file. Tune PHP FPM: https://www.if-not-true-then-false.com/2011/nginx-and-php-fpm-configuration-and-optimizing-tips-and-tricks/

MySQL/MariaDB tuning

Connect to UNIX socket in PHP: When the host name is set to „localhost“, then the connection to the server is made thru a domain socket by default. Check following parameters in /etc/mysql/my.cnf: max_connections table_open_cache thread_stack read_buffer_size join_buffer_size sort_buffer_size key_buffer_size Table size max_heap_table_size tmp_table_size Query cache query_cache_limit query_cache_min_res_unit query_cache query_cache_size Weiterlesen…

Create and automatically renew Letsencrypt certificate

Originally found here https://decatec.de/home-server/owncloud-9-auf-ubuntu-server-16-04-lts-mit-nginx-mariadb-php-7-und-lets-encrypt/. Thanks for the great setup guide! But due to a problem with my nginx setup I have to update my nginx config every time I want to renew the certificate. On SurServ sudo su cd /etc/nginx/conf.d nano surrouter.asuscomm.com comment out: return 301 https://$server_addr$request_uri; CTRL+O and CTRL+X service nginx Weiterlesen…

Nginx Server tuning

test page: https://gtmetrix.com/ CACHE!!! https://www.digitalocean.com/community/tutorials/how-to-implement-browser-caching-with-nginx-s-header-module-on-ubuntu-16-04 https://codex.wordpress.org/Nginx let google host jquery https://www.nginx.com/blog/9-tips-for-improving-wordpress-performance-with-nginx/ https://docs.nextcloud.com/server/12/admin_manual/configuration_server/server_tuning.html#enable-php-opcache Add those options somewhere in /etc/php/7.0/cli/php.ini and /etc/php/7.0/fpm/php.ini   Nginx and PHP-FPM Configuration and Optimizing Tips and Tricks http2 server push: https://www.nginx.com/blog/nginx-1-13-9-http2-server-push/ use unix sockets where possible: http://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_pass unix inter-process communication benchmark: http://www.cl.cam.ac.uk/research/srg/netos/projects/ipc-bench/ reuseports: https://www.nginx.com/blog/socket-sharding-nginx-release-1-9-1/ –> does not seem to work Weiterlesen…