Monday, January 18, 2021

phpLiteAdmin : No option visible to create / rename / delete database

If you have installed phpLiteAdmin in your Apache but you are unable to see the options to create / rename / delete database. Here is the solution for you.

Solution :

Your php code of  phpLiteAdmin does not have sufficient permission to show these options. You need to change the owner of the folder phpLiteAdmin.

If you have installed phpLiteAdmin in CentOS, your httpd user is apache, change the owner of the folder.

chown -R apache:apache phpLiteAdmin
If you have installed phpLiteAdmin in Ubuntu, your apache user is www-data, change the owner of the folder.
chown -R www-data:www-data phpLiteAdmin

If you have installed phpLiteAdmin in Lampp/Xampp, your apache user is daemon, change the owner of the folder.

chown -R daemon:daemon phpLiteAdmin

Now open again phpLiteAdmin in the browser. You should be able to see all options.

You can also try with 777 permission to the folder phpLiteAdmin but this is not a good practice to give full permissions to a folder of Document Root.

AWS S3 Copy Error - Connection was closed before we received a valid response from endpoint URL

 aws s3 cp error :


Error : upload failed: ./file.txt to s3://bucketname/file.txt Connection was closed before we received a valid response from endpoint URL: "https://bucketname.s3.amazonaws.com/file.txt"
Solution :

You are getting this error because you did not configure your aws bucket region in your ec2 instance. 

I did not get this error every time. When my bucket was in Mumbai region (ap-south-1), I did not need to configure bucket region in my ec2, I got this error when one of my bucket was in North California (us-west-1) region but it is a good practice if you configure your bucket region always.

Configure aws with region.

aws configure

It will ask for access key and secret key. If you have then you can enter, if you do not have like you attached the role with your ec2 instance, then you can skip it by simply pressing return key.

Now it will ask 'Default region name'. This is the attribute for that you are configuring aws. Check your bucket's region and enter here.

Example : If your bucket is in North California then your region will be us-west-1.

Skip the 'Default output format' and try to copy again using `aws s3 cp` command.

You should not get the same error again.

Saturday, December 19, 2020

Google Chrome GPU process Error

If you are facing gpu process error in your google chrome after upgrade or if the error starts appearing suddenly, this solution should work for you.
To find the error, you need to start the chrome from terminal then only you will be able to see the error.


In regular way, Chrome does not open. You click on the icon and it does not happen anything that's why you are not able to detect the error.


In some cases, chrome starts with half black and half white screen and you cannot type anything because cursor does not appear.

If you are a root user then you need to start the chrome with given command.

google-chrome --disable-gpu --disable-software-rasterizer --no-sandbox

or you can start it using icon too but it is not working so you need to update a line in the file /opt/google/chrome/google-chrome.
Find last line in the file. It should be something like this.

exec -a "$0" "$HERE/chrome" "$@"

Replace the line with

exec -a "$0" "$HERE/chrome" "$@" --disable-gpu --disable-software-rasterizer --no-sandbox

Now click on the chrome icon, it should be opened properly.