Remove a range of lines from a huge file

When you have to deal with a huge file containing gigabytes of data and need to delete a range of lines from it, opening it with a text editor can be a fatal mistake. As an example, in this post I will demonstrate how to delete a whole database out of a huge SQL dump without messing around with a text editor. Continue reading

Posted in Linux Administration | Tagged , | Comments Off on Remove a range of lines from a huge file

Migrate WordPress site with minimal downtime

Migrating a Wordpress installation from one server to the other sounds like a simple task. Just move the files, copy the database for Wordpress and lets go. But when you start dealing with the DNS entries the whole story gets tricky. Continue reading

Posted in DNS, Security | Tagged , , , | Comments Off on Migrate WordPress site with minimal downtime

Setup Postfix for multiple domains

If you have postfix configured as your mail server you have most likely configured it forĀ one particular domain. If you have more then one domain, you can configure postfix to handle those as well to receive emails for them. In … Continue reading

Posted in Mailserver | Tagged , | Comments Off on Setup Postfix for multiple domains

Create webupload user for SCP

With a website running on your server you might have come across the permission problems when uploading files to the document root. Files are owned by the upload user, apache can read them but upload and modification via the web front-end fails and much more. The reason is the permission and ownership structure in Linux. But how to solve that mess? Continue reading

Posted in Linux Administration | Tagged , , | Comments Off on Create webupload user for SCP

Access the internet from server without direct connection

When two servers are connected to each other but only one server has access to the internet, it is always complicate to connect to the server without internet connection as well as you need internet connectivity to update/install packages from the repositories. Here is how you get ride of all the restriction to work comfortable even with the server that has no direct internet access. Continue reading

Posted in Linux Administration | Tagged , | Comments Off on Access the internet from server without direct connection

Using the Symfony Validator as a standalone component

It’s easy to think of SymfonyĀ as just being a huge full-stack PHP framework, that you either base your entire project around or ignore completely, but in fact, the individual Symfony components canĀ be surprisingly easy to slot into an existing project.Ā This … Continue reading

Posted in PHP | Tagged , , | Comments Off on Using the Symfony Validator as a standalone component

Show installed yum packages by size

When you pay for every GB of disc space on your server as it is with an Amazon EC2 instance, you want to make sure that the installed packages are at a minimum. Besides the actual user data, you can as well try to remove packages you don’t need but have been installed for some reasons. Here is how to find the biggest installed packages. Continue reading

Posted in Linux Administration | Tagged , , , | Comments Off on Show installed yum packages by size

Setup Postfix with SMTP-AUTH and TLS on CentOS

Understanding Postfix Postfix is like a router in a network, just for email traffic. It receives emails from a sender and tries to send them on to theirĀ recipient, where the recipient can be the local postfix server or some other … Continue reading

Posted in Mailserver | Tagged , , , , | 1 Comment

Increase Amazon EBS Volume of a Linux EC2 instance

Increasing the size of a EBS volume is sadly not as easy as tweaking a value. Amazon AWS does not support changing the Volume size on the fly. But there are ways to increase the size. Continue reading

Posted in Linux Administration | Tagged , , | Comments Off on Increase Amazon EBS Volume of a Linux EC2 instance

Access SSH server without direct connection from the internet

When two servers are connected to each other but only one server has access to the internet, it is always uncomfortable to connect to the server without internet connection. Specially when files need to be copied to the server without direct internet connection. There is a way to make it more comfortable to connect via ssh. Continue reading

Posted in Linux Administration | Tagged , , | 1 Comment