[HOW TO] Ibus ibus-unikey on Elementary OS | install ibus-unikey on ubuntu | can not install ibus-unikey on ubuntu

have you ever installed ibus-unikey in elementary OS?

A few days ago, I have issues with it. Avowedly, I installed, also add vietnamese keyboard into keyboard input method. What's happened?

And finally, I see it. If you have the save issues, you can use this tip to solve this.

To start, you must install dconf-editor,
org\gnome\desktop\applications\input-sources

per-windows: checked
sources: [('xkb','us'),('ibus','Unikey')]
xkb-options []

now you use Crl + Space to switch language.

 Thank you for reading this article, please a comment if you are interested.

Tiến Phan - R0039

Knowledge is Endless

Sharing for Success

[HOW TO] install driver canon in linux | install canon printer in ubuntu | install canon mf3010 in elementary OS

Yesterday I have tried to install Canon Printer MF3010. It is not easy as me think.

Firstly, I come to canon officially of MF3010 to downloaded driver. But it is not success. I still can not install MF3010. What the help?

Workaround, I think that the driver still can not install truly. Where? 

or

It help me to resolve the problem with driver MF3010 in Elementary OS. Hope this help for you.

 Thank you for reading this article, please a comment if you are interested.

Tiến Phan - R0039

Knowledge is Endless

Sharing for Success

Grail run-app | Grails run-app change default port | Grail run app locally



You need to run app in grails before deploying it on your web application. Luckily, grails support them.

Simply you do follows:

1. Go to your grails directory
2. Use "grails run-app" command
3. If you want to change default port of grails run-app 8080. How to? Use command:  grails -Dserver.port=9001 run-app


Run the grails run-app command.
The grails run-app command starts the Enterprise Server in the background and runs the application in one step. You don't need to create a WAR file or deploy your application.
To test your application, point your browser to http://host:port/app-dir-name.
For example, point to http://localhost:8080/helloworld. You should see a screen that begins, “Welcome to Grails.” Selecting the HelloController link should change the display to, “Hello World!”
Link reference: https://docs.oracle.com/cd/E19776-01/820-4496/ghflk/index.html

 Thank you for reading this article, please a comment if you are interested.

Tiến Phan - R0039

Knowledge is Endless

Sharing for Success

HOW DO I GRANT PRIVILEGES IN MYSQL?


Grant for each table:
GRANT permission ON database.table TO 'user'@'localhost';

Grant for database:
GRANT permission ON database.* TO user@'localhost' IDENTIFIED BY 'password';

Once you have given the desired privileges for your user, you will need to run this command within the MySQL command prompt:
FLUSH PRIVILEGES;

To see a list of the privileges that have been granted to a specific user:
select * from mysql.user where User='username';

PrivilegeMeaning
ALL [PRIVILEGES]Sets all simple privileges except GRANT OPTION
ALTEREnables use of ALTER TABLE
CREATEEnables use of CREATE TABLE
CREATE TEMPORARY TABLESEnables use of CREATE TEMPORARY TABLE
DELETEEnables use of DELETE
DROPEnables use of DROP TABLE
EXECUTENot implemented
FILEEnables use of SELECT ... INTO OUTFILE and LOAD DATA INFILE
INDEXEnables use of CREATE INDEX and DROP INDEX
INSERTEnables use of INSERT
LOCK TABLESEnables use of LOCK TABLES on tables for which you have the SELECT privilege
PROCESSEnables the user to see all processes with SHOW PROCESSLIST
REFERENCESNot implemented
RELOADEnables use of FLUSH
REPLICATION CLIENTEnables the user to ask where slave or master servers are
REPLICATION SLAVENeeded for replication slaves (to read binary log events from the master)
SELECTEnables use of SELECT
SHOW DATABASESSHOW DATABASES shows all databases
SHUTDOWNEnables use of MySQLadmin shutdown
SUPEREnables use of CHANGE MASTER, KILL, PURGE MASTER LOGS, and SET GLOBAL statements, the MySQLadmin debug command; allows you to connect (once) even if max_connections is reached
UPDATEEnables use of UPDATE
USAGESynonym for privileges
GRANT OPTIONEnables privileges to be granted

what are the differences between CSV and XLS?

Today I think about CSV file & XLS file, and what are the differences between them?

Humhum, as I known that XLS is file format of Microsoft Excel. CSV is format frequently export by IT man.

Google now, I get one result:

Comma-Separated Values (CSV):These files hold plain text as a series of values (cells) separated by commas (,) in a series of lines (rows). You can actually open a CSV file in a text editor. Many applications are capable of reading CSV files, and many languages provide built-in functions that simplify reading/writing CSV format.


Excel (represented as XL) Spreadsheet (XLS):It is an MS Excel workbook binary file, which holds information about all the worksheets in a workbook, comprising both content and formatting (number masking, colouring, conditional formatting, etc), and can also hold additionals like charts, images, etc. XLS files can only be read by applications that have been especially written to read their format, and can only be written in the same way.

Source: internet

Thank you for reading this article, please a comment if you are interested.

Tiến Phan - R0039

Knowledge is Endless

Sharing for Success

[HOW TO] reset password MAC OS 10.11

Do you want to reset Mac's password?
Unlucky, you do not know how to do it.

Ok, no problem. Here I show you.

Solution 1:
Access Single-User mode.

a. Shutdown your computer.
b. Use hand to hold down the "Command" key and "S" key. Hold both of these together and do not let go through the next step.
c. Wait until you see a bunch of white writing scrolling by on a back screen. Now you are in Single-User mode.
d. mount -uw /
e. launchctl load /System/Library/LaunchDaemons/com.apple.opendirectoryd.plist and press [Return]
f. ls /Users and press [Return]. A list of all of the accounts on your computer will be listed
g. dscl . -passwd /Users/your_username your_password
h. Restart the computer and try the new password.

Solution 2:
Recovery mode
a. Shutdown your computer.
b. Use hand to hold down the "Command" key and "S" key. Hold both of these together and do not let go through the next step.
c. Wait until you see a bunch of white writing scrolling by on a back screen. Now you are in Single-User mode.
d. mount -uw /
e. rm /var/db/.AppleSetupDone . Remove the hidden file that trigger’s OS X to skip the setup assistant at startup:
f. type "reboot" to restart your Mac.
g. now configure with a new account (user/password)
h. after login, you can change the password of previous user.

Thank you for reading this article, please a comment if you are interested.

Tiến Phan - R0039

Knowledge is Endless

Sharing for Success


[NOTE] The core file in linux

Warning!
The core file contains a memory dump of a worker process
at the moment of a crash and therefore can contain sensitive
information, such as passwords, keys, or private data. Therefore,
never share core files with people you don't trust.

In Linux I Trust

Thank you for reading this article, please a comment if you are interested.

Tiến Phan - R0039

Knowledge is Endless

Sharing for Success

[HOW TO] lsyncd: Error, Consider increasing /proc/sys/fs/inotify/max_user_watches | lsyncd dead but pid file exists

hello,

30 minutes ago, I go around our server to ensure the data synchronization runs day-by-day. But ...
It is not run 3 days ago.

What happened?

Ok, step-by-step

Check lsyncd:
[root@01 ~]# /etc/init.d/lsyncd status
lsyncd dead but pid file exists

Huh-uh,
[root@01 ~]# less /var/log/lsyncd/lsyncd.log
lsyncd: Error, Consider increasing /proc/sys/fs/inotify/max_user_watches

How to fix?

$ echo 524288 > /proc/sys/fs/inotify/max_user_watches

man inotify(7) says:
The following interfaces can be used to limit the amount of kernel memory consumed by inotify:
/proc/sys/fs/inotify/max_queued_events 
The value in this file is used when an application calls inotify_init(2) to set an upper limit on the number of events that can be queued to the corresponding inotify instance. Events in excess of this limit are dropped, but an IN_Q_OVERFLOW event is always generated.
/proc/sys/fs/inotify/max_user_instances 
This specifies an upper limit on the number of inotify instances that can be created per real user ID.
/proc/sys/fs/inotify/max_user_watches 
This specifies an upper limit on the number of watches that can be created per real user ID.

Restart lsyncd
[root@01 ~]# /etc/init.d/lsyncd restart
Stopping lsyncd:                                           [FAILED]
Starting lsyncd:                                           [  OK  ]
[root@01 ~]# 
[root@01 ~]# /etc/init.d/lsyncd status
lsyncd (pid  605) is running...

Hope this help!

Thank you for reading this article, please a comment if you are interested.

Tiến Phan - R0039

Knowledge is Endless

Sharing for Success

[HOW TO] Dumping and importing from/to MySQL in an UTF-8 safe way

to avoid your shell character set from messing with imports, use -r to export and SOURCE when importing.
Export: mysqldump -uroot -p database -r utf8.dump
Import: mysql -uroot -p --default-character-set=utf8 database
mysql> SET names='utf8'
mysql> SOURCE utf8.dump

 Thank you for reading this article, please a comment if you are interested.

Tiến Phan - R0039

Knowledge is Endless

Sharing for Success