General :: Remove Write-Protected File - Will It Actually Delete The Password File?
Jul 30, 2010
When I ls -l /etc/passwd, -rw-r--r-- 1 root root /etc/passwd When I login as myself, and rm /etc/passwd, it asks: rm: remove write-protected file '/etc/passwd'? If I say yes, will it actually delete the passwd file?
This is sort of a weird question.'m helping an agency develop a Microsoft Access database. They use windows and I use Fedora. I can run Access in Crossover Office if I don't get too fancy.I've sent what I've done to them for their review and comments and somehow it has become password protected. I've checked the Access settings and their is no password set from Access. I've tried a chmod666 on the file and sent it to him again and he says it is still calling for a password
I created a password-protected .doc file in Windows yesterday using the latest version of OpenOffice (3.2.1)Opening the file worked perfectly; double-clicked the file, OpenOffice popped up and prompted me for the password, then it let me edit the document as usual.Tried it on another computer with Microsoft Word; worked perfectly as wellFor some reason though, it won't work in Ubuntu (10.10). I'll double-click the file, it'll open with OpenOffice and prompt me for the password, but once it opens it's in "Read Only" mode.I tried it on another Windows computer, just to see if it would work, and it did.I right-clicked the .doc file and looked at the permissions: (picture edited for privacy)Every time I tried changing it from "Read-only" to "Read and write" it automatically (and immediately) switched back to "Read-only"
Been thinking about a new backup-strategy for my family and me. In our house is an Ubuntu Server (10.10) and NAS (Zyxel NSA210). Now I thought I'd create a Cron Tab entry on all machines which will sync specific folders automatically to either the NAS or a specific backup drive in the server. So now the question is: "How do I do that without seriously compromising each family members privacy by making their backed up files available to everyone in the house?" So in essence I'd like to sync/back up the files to a password protected share for each family member. But this process should still be done automatically every few minutes or so without them having to enter any password at all as their specific password is stored locally.
remove a line starting with specific word with grep. Here is what I found
grep -v '^cc$' data.txt
Here I remove all lines with on 'cc' in that line. But I want the result write back to data.txt
I try several ways
grep -v '^cc$' data.txt > output.txt # works but to another file echo `grep -v '^cc$' data.txt` > data.txt # didn't work, all carets gone, become one line grep -v '^cc$' data.txt > data.txt # data.txt is empty after running this
How can I save the result of grep to the input file?
I am using F14 Xfce and i have installed awn so i do not need my desktop icons anymore, ie home,bin and file system, is there any way to delete/remove them? i have installed gconf-editor and unchecked them in apps-->nautilus-->desktop, but they are still there?
Many folders within a subdirectory some of which have lots of data in and some of which have only one specific file called produkt.fil inside.I need a command to find and delete those folders that contain ONLY the file produkt.fil - if other files exist (doesnt matter what they are) then they should be left alone. Note: produkt.fil exists in all of the folders always.
At work I'm using a windows box with local and network drives. One of drives I have mapped is my Linux home directory (We have separate windows and linux accounts and home directories here). When I view it from windows, all of the files and folders beginning with . are shown, as would be expected. (Although . and .. aren't in any folder)
Just wondering if there is a way to tell windows to not show anything starting with a dot. I was hoping there's a registry entry or something that defines what a 'protected operating system file' is, so I could put dot files in the same category as thumbs.db etc.
I use Ubuntu 9.04 exclusively on my own machines, but I have a couple of flash drives that got infected by some corrupt windows executable (*.exe) files, probably by somebody's trojan (they are Cruzer 4GB so came with installed fancy programs that I dont need but didnt remove and Windows keeps installing unwanted ini files and other trash every time I use them in somebody elses machine or in an internet cafe). I deleted quite a few files, but some are stubborn. $ sudo chmod +w-X doesnt seem to work. How do I unprotect and remove them? The filesystem is vFAT.
I suspect the files were created by some kind of a trojan as my work requires my flash to be pretty promiscuous. When I 've backed up all the good files I need, I'd be happy to reformat the flash drives as straight vanilla data storage and retrieval, provided I can still use them on a variety of machines running MS windows as well as on my Linux machines. Any guidance on reformatting?
What are the possible problem when Windows access the file from Ubuntu got Read Only even though have a full permission to read, write and execute the file? Ubuntu to Ubuntu accessing the file there is no problem only Windows got a problem.
Well here's what I've done in grub.confpassword --md5 BLABLABLA /grub/admin_menu.lstNow that I enter some password, I can go to that menu and run my pvt. OS.But how to get back to original (or say public or default) grub menu?
we assume that we have 2 folders with the name 1 and 2 . The folder 2 is inside 1 . Also, in folder 2 we have file with name "file.txt". And we are in folder 1 . How can we delete the file.txt in one command line ? I mean without using the code below: