Unable to install MySQL 5.7.12 in RedHat in a separate directory I am trying to install the MySQL version 5.7.12 into RedHat in a non default data path.

The installation syntax used

/app/mysql/5.7/bin/mysqld --initialize --user=mysql --basedir=/app/mysql/5.7 --datapath=/app/mysql/data


/app/mysql/data is a softlink to /data

I got the following error.

2016-05-19T02:57:28.087915Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicitdefaults_for_timestamp server option (see documentation for more details).
2016-05-19T02:57:28.090891Z 0 [ERROR] --initialize specified but the data directory has files in it. Aborting.
2016-05-19T02:57:28.090910Z 0 [ERROR] Aborting
bin/mysqld --initialize --user=mysql --datadir=/app/mysql/data --basedir=/app/mysql/5.7

I specified --user parameter and the error no longer appearing. 

2016-05-19T10:27:17.440353Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2016-05-19T10:27:17.661087Z 0 [Warning] InnoDB: New log files created, LSN=45790
2016-05-19T10:27:17.713953Z 0 [Warning] InnoDB: Creating foreign key constraint system tables.
2016-05-19T10:27:17.777797Z 0 [Warning] No existing UUID has been found, so we assume that this is the first time that this server has been started. Generating a new UUID: xxxxxxx-xxxx-xxxx-xxx-xxxxxxx.
2016-05-19T10:27:17.780306Z 0 [Warning] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
2016-05-19T10:27:17.781230Z 1 [Note] A temporary password is generated for root@localhost: xxxxxxx