Mysql installation - Operation not permitted


 
Thread Tools Search this Thread
Top Forums UNIX for Beginners Questions & Answers Mysql installation - Operation not permitted
# 8  
Old 04-27-2019
Boris,

You do not need to use sudo when you are root.

Also, you could have tested easily by manually moving or copying the config file in your original post as root.
# 9  
Old 04-27-2019
Thanks Neo,
I tried sudoedit, gedit etc but none of them worked.
It was saying read only. Also rm command was not responding..
I suppose after upgrading from ubuntu14.04 to 16.04, I broke my repositories and made some non-returnable changes so that the system could not have repaired it. I am not a professeur on linux :/ You all may guess what could be the solution.

Thank you
Boris
# 10  
Old 04-27-2019
If you are root and cannot perform simple operations like move, copy and edit you need to check your filesystem to insure it is not mounted read only.
This User Gave Thanks to Neo For This Post:
# 11  
Old 04-28-2019
There is one more thing that could be an issue, denying deletion ever for root.

Check in the working directory with command lsattr /etc/mysql
The former admin perhaps implemented immutable flag with chattr +i <file>

Until that flag is removed with chattr -i <file>, you won't be able to do much with file except reading it.

Very underused and forgotten feature.

Example :
Code:
root@hickup:~/example# pwd
/root/example
root@hickup:~/example# printf "%s\n" "some text" > example.conf
root@hickup:~/example# chattr +i example.conf 
root@hickup:~/example# lsattr example.conf 
----i---------e---- example.conf
root@hickup:~/example# rm example.conf 
rm: cannot remove 'example.conf': Operation not permitted
root@hickup:~/example# rm -f example.conf 
rm: cannot remove 'example.conf': Operation not permitted
root@hickup:~/example# printf "%s\n" "Add text" >> example.conf 
-bash: example.conf: Operation not permitted
root@hickup:~/example# mv example.conf example2.conf
mv: cannot move 'example.conf' to 'example2.conf': Operation not permitted

Hope that helps
Regards
Peasant.
This User Gave Thanks to Peasant For This Post:
# 12  
Old 04-28-2019
Before setting with chattr , the OP should probably list first, for example:

Code:
lsattr example.conf

The OP said he does not have any experience in Linux, so before going around changing file attributes, he should list them first before he makes even more mistakes.

My first guess is the the file system has been mounted read-only.

Smilie
# 13  
Old 04-28-2019
Thank you Peasant,
I will record this into my notes.


Kind regards
Boris
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Ubuntu

Mysql apache installation

on ubuntu lamp server how to install mysql and apache? any instructions? (1 Reply)
Discussion started by: srinathk
1 Replies

2. Shell Programming and Scripting

need command for mysql installation

Hi All, I want to install mysql on my server but i dont have root access when i have tried to install this MySQL-client-3.3.15-3.rhel5.x24_74.rpm using the command rpm -ivh MySQL-client-3.3.15-3.rhel5.x24_74.rpm getting error error: can't create transaction lock on... (0 Replies)
Discussion started by: aish11
0 Replies

3. Shell Programming and Scripting

mv warning set owner/group: Operation not permitted

Hi, Thanks for looking into this. I am running into below situation in free BSD. I have a file in /tmp/sample.txt with owner as 'xyz' and group as 'wheel' I am moving it to my home dir/newsample.txt whihc has owner 'xyz', but group 'someother' with below command, getting warning, but it is... (2 Replies)
Discussion started by: ramanaraoeee
2 Replies

4. UNIX for Dummies Questions & Answers

chown: Operation not permitted as root

Hi Expert, I am trying to change ownership of one file to another user that is exist in the system but getting operation not permitted error what could be the correct way? # ls -lh .Xauthority_ori -rw------- 1 maxim atlas 2.8K Jul 27 17:18 .Xauthority_ori # id -a uid=0(root)... (8 Replies)
Discussion started by: regmaster
8 Replies

5. AIX

AIX5.3--vmount: Operation not permitted

Hi all, iam unable to mount exported directory hari on AIX 5.3, which was in RedHat Linux As4. Linux-server AIX -client I am facing errors of bash-3.00# mount -n linuxas4 /hari /hari mount: 1831-008 giving up on: linuxas4:/hari vmount: Operation not permitted. Pl any body... (1 Reply)
Discussion started by: haribabu
1 Replies

6. Linux

failed to preserve ownership operation not permitted

Hi i have written one backup script in linux workstation.The backup script will do zipping files and moved to the backup directory(i,e /net/ts-bcn/sb_backup/sand). #So while moving zipped files to the backup directory i am getting some error like this error:mv:failed to preserve ownership... (2 Replies)
Discussion started by: yogks
2 Replies

7. Shell Programming and Scripting

Cannot utime: Operation not permitted

Hi - I have a script (.ksh) which has been transferred from one Linux box to another. Basically it untars a file a deploys the code to the relevent directories. It is failing with ' Cannot utime: Operation not permitted' When I run the command by hand it *is* doing the untar to the directories... (1 Reply)
Discussion started by: ajcannon
1 Replies

8. Linux

MySQL python installation

Hi I am using CentOS 4 machine..trying to install MySQL for python to setup a boinc project.. During the building process I am getting this error..I have even set the LD_lIBRARY_PATH to /usr/local/lib where the libmysqlclient.so file is present.. ./python -E ./setup.py build ./python: error... (1 Reply)
Discussion started by: Gayathrirri
1 Replies

9. Programming

pthread_create returns "operation not permitted" if I try to link static?

Hello, I am trying to port some testtools we wrote from solaris to redhat linux(AMD64). If I link dynamic, set the correct LD_LIBRARY_PATH, everything runs fine. If I try to link static, the pthread_create returns "operation not permitted" (error code 1). Does anybody have an idea where to... (1 Reply)
Discussion started by: Micky
1 Replies

10. UNIX for Dummies Questions & Answers

"Operation not permitted" when copying directories

I'm kicking Unix questions out like Bruce Lee. So I'm copying a directory of files, in each directory I inevitablly get this: I get that for usually the same set of directories/files in each folder. Is there a way to override this when copying files? (4 Replies)
Discussion started by: JPigford
4 Replies
Login or Register to Ask a Question