Category Archives: General

Find MAC Address of your Mac or Linux

Sometimes when you want to connect your computer to a new network via ethernet cable, network administrators may ask for your ethernet port MAC address (a.k.a physical address). There are several ways to find this address which is basically a number in a specific format and I’m going to explain these ways for all Linux-based operating systems in this post.

Continue reading Find MAC Address of your Mac or Linux

Generate & Compare MD5, SHA1 for Files and Strings in Terminal

Most of the times when you download a file from internet, you will see a checksum or MD5 hash tag beside the download link so you can compare the checksum of the downloaded file with the original file. There are several security reasons for that, but the most common one is to eliminate the possibility of a special type of hacking called “Man in the middle”. In this type of hacking, the hacker usually sniffs and listens to the requests goes from your computer and tries to compromise the packets, but the best thing you can do to help the hacker is to request a very popular application that he has already prepared an infected version, so when you want to download the file, he will send his own infected version toward your computer and you will install that application, thinking that it is the original malware-free application !! so after installing the application, the hacker can do variety of dangerous things to your computer such as creating a backdoor, key-logging, screen capturing, infecting the entire trusted network and etc.

The only way you can avoid this type of hack is by checking the checksums. there are few awesome, useful and easy commands that can do this checking for you and I’m going to describe them in this article:

Continue reading Generate & Compare MD5, SHA1 for Files and Strings in Terminal

Find and replace a string in entire mysql database

Most of the time when you want to copy a website for another use or even when you are changing your URL, you face this problem that you should search for the old URL among all records of database and then replace it with new one.

There are many ways and many scripts designed for this issue and each has a disadvantage.

I faced this problem and tested few of these ways but they are mostly causing more problem, specially when you have too many tables and too many columns. So I found the following way and it worked like charm:

Continue reading Find and replace a string in entire mysql database

Error: “Error getting a Request Token: Bad Request”

Q: Why do I receive this error “Error getting a Request Token: Bad Request” when I try to add Online Account to my Linux?


A: This Error pops up when your computer time is not acceptable by Google server. This issue can be solved by setting your computers time and region.

In below you can see the link of RedHat Bugzilla post about such a problem.:

Edit GRUB list

Usually when you have two operating systems on a single computer and one of them is Linux, you will face this problem that by updating the Linux (especially when your Linux kernel is upgraded) your OS list (if you are using GRUB) order will displayed in a new order and the Linux with new kernel will become the first choice of the list. Apparently this is hard for most of people if their first choice was alwas the other OS (usually Windows), because in GRUB after few seconds, if you don’t press any key the GRUB it self will select the first choice, and after the recent update the first choice has changed. By following the steps below, you can reorganize the GRUB list order. Continue reading Edit GRUB list