I know there are already several postings on the stackexchange sites about Linux permissions, but I can't find the answer to my problem.
I'm working on my own laptop (no web server or anything) with mySQL. I'm using mySQL directly from the console client. Frequently, I want to run a query and save the results elsewhere for further work in LibreOffice or whatever. I use
select ... into outfile 'path+file';. Even though I'm logged in as myself, I'm unable to save the output file into my
~/Downloads/ directory, which I'm using as a temp directory. I understand that the mySQL server is running under a special user, not me. Since I'm the only real user on here, I executed
sudo chmod 7777 ~/Downloads, and see it now shows
drwsrwsrwt. After the chmod, I restated the server. However, I still get
ERROR 1045 (28000): Access Denied... if I try to output into this folder when logged into mySQL as me. Logged in as root, I get
ERROR 1 (HY0000): Can't create/write to file ... when I run the same command.
Hence, I'm stuck logging in as root, exporting my data to
/tmp/, then doing
sudo cp from another terminal to get my data. Any suggestions on what I need to do to fix this?