Posts

Showing posts with the label ubuntu

‘Sed’ Command In Linux: Useful Applications Explained

Image
Have you ever needed to replace some text in a file really quickly? Then you have to open up your text editor, find the line, and then type out your replacement. What if you have to do that many times? What if it isn’t also exactly the same thing and you have to run multiple searches and replace each occurrence? It gets tedious very quickly, but there’s a better way of doing it with a tool called sed. We’ve written about POSIX and went over some of the interfaces and utilities a system must provide in order to be POSIX compliant. The command line tool sed is one of those utilities that provide a feature-rich way to filter, find, substitute, and rearrange data in texts files. It is an extremely powerful tool that is very easy to get started with, but very difficult to learn through and through due to its seemingly endless number of features. First, we should note that the GNU implementation of sed, while POSIX compliant, goes above and beyond the specification to provide exte...

Installation and Basic Configuration of Apache Web Server

Image
Hello world, previously we post the definition of web server and how it works. So here how to configure web server using apache. Install apache2 package Check using nmap Check the web server using a browser http://localhost . If it appears like this then it works Installing PHP5 Perform testing on php5 If it looks like the picture above then work and type http: //localhost/index.php. If the result looks like the picture below then it works Install mysql At the time of the installation process is told to go to the root is useful if we need to create a database. Test Mysql service using nmap