check current keyboard map information use following command
recently i installed CentOS 7 and accidentally installed en_gb by default
loadkeys us
localectl status # to display locale settings
localectl set-locale LANG=en_GB.utf8 # to set the Language
localectl list-locales # to lists locales
localectl list-keymaps # list keyboard mappings
localectl set-keymap uk # sets the key map
[root@server1 ~]# mysql_secure_installation /usr/bin/mysql_secure_installation: line 379: find_mysql_client: command not found
NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB SERVERS IN PRODUCTION USE! PLEASE READ EACH STEP CAREFULLY!
In order to log into MariaDB to secure it, we'll need the current password for the root user. If you've just installed MariaDB, and you haven't set the root password yet, the password will be blank, so you should just press enter here.
Enter current password for root (enter for none): <--ENTER OK, successfully used password, moving on...
Setting the root password ensures that nobody can log into the MariaDB root user without the proper authorisation.
Set root password? [Y/n] New password: <--yourmariadbpassword Re-enter new password: <--yourmariadbpassword Password updated successfully! Reloading privilege tables.. ... Success!
By default, a MariaDB installation has an anonymous user, allowing anyone to log into MariaDB without having to have a user account created for them. This is intended only for testing, and to make the installation go a bit smoother. You should remove them before moving into a production environment.
By default, MariaDB comes with a database named 'test' that anyone can access. This is also intended only for testing, and should be removed before moving into a production environment.
Remove test database and access to it? [Y/n] <--ENTER - Dropping test database... ... Success! - Removing privileges on test database... ... Success!
Reloading the privilege tables will ensure that all changes made so far will take effect immediately.
All done! If you've completed all of the above steps, your MariaDB installation should now be secure.
Thanks for using MariaDB! [root@server1 ~]#
now test http://localhost or http://ip_of_server/ on browser it gives you a page like following
Testing 123..
This page is used to test the proper operation of the Apache HTTP server after it has been installed. If you can read this page it means that this site is working properly. This server is powered by CentOS.
that page saying httpd is working fine
now we can install PHP on centos
just run yum -y install php
after installing php httpd requires restart
restart httpd using follwoing
service httpd restart
for test php
create a file including followings
<?php phpinfo(); ?>
and save it in /var/www/html folder as phpinfo.php
check with browser http://localhost/phpinfo.php or http://ip_of_server/phpinfo.php
now install php-mysql using following command to get mysql support in php
yum install php-mysql
then other modules also well
yum -y install php-gd php-ldap php-odbc php-pear php-xml php-xmlrpc php-mbstring php-snmp php-soap curl curl-devel
don't forget to restart apache again service httpd restart
if you need to access mysql using webrowser install phpMyAdmin using following yum install phpMyAdmin
recently i installed centos 7 and happy to say back to play with linux. so as first step after installation was the configure network.
first need to check what are the available interfaces in current system. to check that we can use ifconfing -a command
Screen 0: minimum 320 x 200, current 1366 x 768, maximum 8192 x 8192
LVDS1 connected 1024x768+0+0 (normal left inverted right x axis y axis) 309mm x 174mm
1024x768 60.0
800x600 60.3 56.2
640x480 59.9
VGA1 disconnected (normal left inverted right x axis y axis)
Screen 0: minimum 320 x 200, current 1366 x 768, maximum 8192 x 8192
LVDS1 connected 1366x768+0+0 (normal left inverted right x axis y axis) 309mm x 174mm
1366x768 60.0
1024x768 60.0*+
800x600 60.3 56.2
640x480 59.9
VGA1 disconnected (normal left inverted right x axis y axis)
2.extract it to same location where downloaded place
3. now make a directory named as "Smarty" in /usr/local/lib/php location mkdir /usr/local/lib/php/Smarty
4. copy all the content of lib folder where extracted downloaded file to /usr/local/lib/php/Smarty locate extracted folder (Smarty-xx) & then give cp libs/* /usr/local/lib/php/Smarty
5.Set SElinux to permissive mode. System->Administration->SELinux Management
* Remember to set template_c & cache writable for others