Categories
Unix & Linux

How to prevent SSH connection from freezing

Recently I was finding that my SSH connection to my FreeBSD server was freezing. I’m on macOS Catalina connecting to a FreeBSD box using standard Terminal app. I’m using shared keys and the connection was fine and working well until I left the Terminal window idle for over 15 seconds.

Categories
Unix & Linux

How to install and run Apache Solr 9.x on FreeBSD

Before you begin this guide, you should have a FreeBSD 13.2 server.

Solr needs the Java version 11 or higher. Java 11 has been extensively tested by both automated tests and users through Solr 9. Long Term Support (LTS) for Java 11 is provided from several sources. Java 12, 13, 14, 15 and 16 have no LTS. For this reason, Java 17 is preferred when upgrading Java. But we will use OpenJDK as free and lightweight alternative.

Categories
Unix & Linux

How to migrate from pkg_ tools to pkg on FreeBSD

As you can read on FreeBSD Wiki:

Pkg is the Next Generation package management tool for FreeBSD. It is the replacement for the current pkg_info/pkg_create/pkg_add tools that ports use to register local packages and which provide remote packages. Its main goals are to faciliate remote binary package upgrades. It also works with ports without remote binary packages.

Categories
Unix & Linux

How to upgrade Perl 5.10 to 5.14 on FreeBSD

The port ‘lang/perl5.10’ was removed on 2013-02-04 because: “Has expired: no longer under development, use lang/perl5.16 or lang/perl5.14”. So we need to move from older 5.10 to newer 5.14. To upgrade perl choose port managment tool you like ( portupgrade or portmaster).

Categories
Unix & Linux

Resolving error “tar: Unrecognized archive format on FreeBSD < 8.3"

Today I tried to install phpMyAdmin on older server, running on FreeBSD 8.1, but I’ve got error message:

Categories
Unix & Linux

How to determine current terminal shell in macOS/FreeBSD

Is there an easy way to determine what shell I’m using in terminal?

Categories
Unix & Linux

Log rotation on FreeBSD

I have php-fpm.log which is about 1 gb now. How can I setup log rotation like in linux logrotate?

Categories
Unix & Linux

OSS and kernel panic on FreeBSD

I installed OSS driver from ports and added this line to /etc/rc.conf:

oss_enable="YES"

Now, my system won’t boot at all. It shows kernel panic while booting, dumps core and reboots. I tried booting into single user mode and correcting loader.conf but it isn’t allowing me to save the changes saying “Read only filesystem”.

Categories
Unix & Linux

How to upgrade ZFS pool on FreeBSD

Yesterday I upgraded my web server to the latest version of FreeBSD (9.0-RELEASE). 

Categories
Unix & Linux

How to migrate from MySQL to MariaDB on FreeBSD

Before migration you should create backup of all databases. You can use mysqlhotcopy, Percona Xtrabackup or other methods.