If you have multiple servers connecting to internet, these servers use Samba to share file with each other. Normally, you will Samba server for this purpose. After you install Samba & configure the server, all servers now can access file sharing now. But there is another issue, you realize that internet users can also access these files. How can we block internet users while still these servers sharing file with each other. There are many solutions, but here is my proposal: We create a virtual interface network, all our servers will have a 2nd virtual private interfaces , to do this you can add someRead More →

Just imagine, you manage a server remotely. The server has many disks, one day one of the disk could be failure. How can you tell the onsite engineer which drive is failure? The answer is you need to give the engineer the serial of the drive. So, the next question is , how can i get the serial? When the drive is dead, you can’t not get its serial, so you must record your server hard disk serial number, when something happens, you can access to your document and get it. Here is the command to get the serial number in Ubuntu: myuser@netbook:~$ sudo hdparmRead More →

Simply run this command, replace example.crt with your actual certificate file: $ openssl x509 -noout -text -in example.crt Certificate: Data: Version: 3 (0x2) Serial Number: .. Signature Algorithm: sha256WithRSAEncryption Issuer: C=GB, ST=Greater Manchester, L=Salford, O=COMODO CA Limited, CN=COMODO RSA Domain Validation Secure Server CA Validity Not Before: Sep 10 00:00:00 2014 GMT Not After : Sep 10 23:59:59 2015 GMTRead More →

It’s simple, just run this command $ openssl req -noout -text -in example.csr | grep ‘Signature Algorithm’ Signature Algorithm: sha256WithRSAEncryption If the value is sha256WithRSAEncryption, the certificate is using SHA-256 (also known as SHA-2). Another common value is sha1WithRSAEncryption, that means the certificate is signed with SHA-1.Read More →

I have some videos that i want other people to download it instead of playing it on the browsers. First, i just try to upload that file to my web document folder and share the link, i found that the user can watch the video directly, this is not what i want, i want the user to download it to their computer, then watch it from their computer later. I did some research and i found that there is a very easy way to accomplish, you just need add the following like to .htaccess file AddType application/octet-stream .mpg AddType application/octet-stream .mov AddType application/octet-stream .mp4 ThisRead More →

Login to your Ubuntu, and run the following command: openssl req -nodes -newkey rsa:2048 -sha256 -keyout myserver.key -out server.csr It then will ask you some information for the certificate, fill them in and complete the process. Country Name (2 letter code) []: (FR in France for example) State or Province Name (full name) [Some-State]: (your state or province name, name of your département in France) Locality Name (eg, city) []: (the name of your city) Organization Name (eg, company) []: (your organization name) Organizational Unit Name (eg, section) []: (do not fill – advised – or enter a generic term such as “IT Department”.) CommonRead More →

Do you have this problem ? – you made the changes in /etc/ha.d/ldirectord.cf , – restart ipvsadm : /etc/init.d/ipvsadm restart you see the changes : ipvsadm -L But after sometimes, you go back and check , the weight has been changed ? WHY ? It’s because there are 2 ldirectord ar running ( you can verify by running top command Kill one of them and check the status (ipvsadm -L) it will fix your problemRead More →

Sometimes, you want to remove the replication , it could be because the replication no longer works, or you don’t want to replicate. Here are some commands that you can use Login to mysql: mysql -uroot -p Enter your mysql root password Run the following command to disable the replication with master. STOP SLAVE; RESET SLAVE; change master to master_host=”, master_user=”, master_password=”; On the master, if you want to disable the replication you should login to mysql and run : stop master Delete all .bin file in /var/log/mysql Edit /etc/my.inf and remove the replication sectionRead More →