Programming :: Logging What Files Are Deleted?

Sep 29, 2010

I'm deleting logs after they are backed up. The line below in a script is doing it but I'd like to print the list of files that are deleted into a log file. I tried printf at the end but can't seem to get it to work. I'm not sure how to output that at the end of the string. Also I was looking at man find man and the difference btween -exec and -execdir. I don't understand what it's saying. Is -execdir executing rm m within the /opt/temp/logs directory the difference?

View 4 Replies


ADVERTISEMENT

Programming :: Deleted Files In Directory With So Many Files Without Deleting Directory Itself

Nov 14, 2010

There are millions of files in many directories. Wherenver i try rm * or find or use xargs, they say 'argument list too long' and exit. How can i deleted files in a directory with so many files without deleting the directory itself.

View 3 Replies View Related

Ubuntu :: Deleted Files On USB Drive Not Actually Deleted?

Jun 7, 2010

I searched the forum with various terms and didn't find anything, so my apologies if this is a common and/or newbie problem.It seems that when I have a USB driveplugged in to switch the files around, those that I delete are still taking up space. I first noticed it with a Chinese MP3 player and thought it was the player being crappy. I could still play all the songs that were supposedly gone. Today, I noticed it with a little thumb drive that I've had for years. I plugged it into my husband's computer running winXP, and the files showed up in a weird, unusable form. I was able to delete them for real.

View 4 Replies View Related

Ubuntu :: Moving Files To A Pendrive Renders 0 Bytes Files And Files Gets Deleted

Jun 10, 2011

I get a SD card. Put in the SD reader. It's empty. I go to my super-important-pictures-to-a-monthly-relatory folder and select all files. Select them for MOVE. Paste them on the SD card. When the move/paste process is finished, i click on the "Eject" button on top of the SD card name. Card's ejected. I can't access the card anymore. I take out the card and put on my other computer. From 300 pictures, there are only 10 available, the remaining ones are there, but with 0bytes and unrecoveable. I panic. I go back to my main computer, my pictures are not there anymore. The pictures were on the Home folder. I panic again. I reset the computer and boot on the LiveCD. I install foremost, scalpel, photorec and about everything till my USB drive complains about being filled up. I run everything and I can't recover my files. I'm in the danger of getting fired. Things like that makes Windows sounds more appealing. When you securely remove a pendrive, things get REALLY pasted there before screwing everything up with a removal.

View 8 Replies View Related

Ubuntu :: After Files Deleted Still Shows Up As Full - Shown In Hidden Trash Files

Mar 9, 2011

I have a Kingston 8gb Datatraveler that has been giving me troubles lately. For some reason after I delete files from it it still shows up as full and the files are shown in the hidden trash files. How do I get rid of these files? I can't delete them as they just show back up. Also, I tried to format the drive with gparted and it won't unmount. When I right click and select information, at the bottom it says: Unable to find mount point. Unable to read the contents of the file system. Because of this, some operations may be unavailable.

View 1 Replies View Related

Fedora :: Files Couldn't Be Renamed Or Deleted, The File Manager Said That The Files Didn't Exist - Very Weird?

Jan 13, 2010

On a KDE4 environment after downloading some music from rapidshare with JDownloader the archives self-extracted with the symbol in some of the file names. Those files couldn't be renamed or deleted, the file manager said that the files didn't exist - very weird. The files should have had some swedish characters in their file names. Now I'm stuck with those files on my machine. Anyone knows how to get rid of them?

View 2 Replies View Related

General :: Unconsciously Deleted The Project Files \ Way To Restore The Files?

Apr 16, 2011

I was working on my Ubuntu lab machine and unconsciously deleted the project files I was working on. I have been working on the project since last 10 days now. Is there a way to restore the files? I do not have sudo access. I was working in my home directory which is served by a common file system (serving all the lab machines).

View 1 Replies View Related

Server :: Iptables Logging To 3 Log Files?

Jul 21, 2010

Whether I use ufw or firestarter to populate my iptables, my firewall logs get written to 3 different log files:/var/log/messages/var/log/kern.log/var/log/syslogI want to keep the logging turned on, but I'd rather it not log to syslog, as it's obscuring other events in syslog that I'd like to see. I'm using rsyslog on Ubuntu. I looked around online and found one person suggesting I add this to the top of rsyslog.conf:kern.* -/var/log/kern.logkern.* ~I did that and restarted rsyslog, but it's still logging to the same 3 files.

View 4 Replies View Related

Software :: Logging To Two Log Files Simultaneously?

Oct 28, 2010

I'm looking for a way to use klogd and/or syslogd to log all the default message levels to the standard /var/log/messages. I also want all kernel (and possibly user) error messages to also be logged to a second file. Is this even possible?

View 3 Replies View Related

Programming :: Add Logging To Shell Scripts?

Jan 1, 2010

I have some simple shell scripts that perform backups and I was wondering how do I add logging? More specifically writing to a log file if any part of the script fails. An example of what my shell scripts look like:

[code]...

View 4 Replies View Related

General :: Where Are Deleted Files Kept

May 1, 2010

Ubuntu 9.10 I recently deleted some files. I would like to know are the files kept in a directory? Like in windows recycle bin. I would like to know where these files are?

View 2 Replies View Related

Server :: Can .pyc And .pyo Files Be Deleted?

Jan 31, 2011

I have a lot of .pyc and .pyo files and I really need the space. I was wonder if I can remove them as I know python will create them automatically.At the moment, I need to make sure I have the space and only this files I can delete... should this be fine?

View 5 Replies View Related

Programming :: Bash Scripting - Logging To The Virtual Account?

May 21, 2011

I need to write a bash script that will allow me to manage my "virtual network" (in reality just a bunch of directories and files). I need to obtain something like : I have my own command 'connect'. We can use it in two different modes: user and admin. If I type 'connect adashiu virtual_machine_name, computer will ask about password, if password is correct he will change a prompt to :

adashiu_at_virtual_machine_name >

after that user can start to use commands reserved only for user mode. Analogically with admin mode: prompt 'admin >' and administrator can only use bunch of commands reserved for him. changing prompt and separated commands for user and admin ?

View 8 Replies View Related

Programming :: Checking List Of Logged In Users - Without Logging Into Pc

Jul 17, 2010

It is possible to check who logged in with "who" command. If we are also logged in to that linux pc.

But, is there any possibility to check without our login?(not even by ssh)

Our logging in to find that pc, will be wasting the cpu resources. And may disturb the user who is working on the x-session.

View 7 Replies View Related

Programming :: Expect/TCL Logging - Create A Clean Log File?

Apr 14, 2011

I've written an Expect script that assists with change management on Cisco devices. The script creates log files for pre-change, the change itself, and post-change. Each log and its commands is triggered by a ! command. For example:

Code:

./dochange.exp hostname
<script spawns bash, user SSHes to hostname>
!PRE

[code]....

All of this works fine. My big hair-pulling hiccup is that the resulting log files are filled with raw backspace characters! I am using log_file to log the output from the script. I stop and restart logging with a new file when needed. However, the log files are pretty much unusable. After doing some research, it looks like log_file sends output to the file in real-time, unbuffered. When I hit a key, it's immediately sent to the log. What I would like is for only the resulting string to go to the log. If I start to type 'reload' and instead type 'show run', I don't want 'reload' to be listed in the log at all.

View 1 Replies View Related

Programming :: Shell Script That Will Automatically Get Executed On Logging In?

May 29, 2011

I want a script to get executedutomatically whenever I login.Code is simple:Quote:dateYEs! it prints the date on the screen.I read somewhere that there is login.sh shell script which get executed automatically whenever one opens console.But how to insert the above code into it.?Also, we can put our command in $HOME/.bashrc and it will get executed everytime I start the interactive shell.

View 1 Replies View Related

Fedora :: Where Deleted Files And Directories Kept?

May 1, 2010

Fedora 13

I recently deleted some files. I would like to know are the files kept in a directory? Like in windows recycle bin. I would like to know where these files are?

View 4 Replies View Related

Fedora :: How To Recover Deleted Files

Jan 31, 2011

I had a back-up of the files of someone . He realized that he wants those files , after I had deleted them . And now I need to recover them . How can I do that?

View 5 Replies View Related

General :: How To Recover Deleted Files

Apr 18, 2010

My laptop has two os. one is windows vista. and other is Ubuntu. I am currently on ubuntu system, this is my primary OS.There are 4 partitions of my hard diskWindows OSLinux(Ubuntu OSData Now the problem part. The data partition is NTFS. I have mounted this partition on the location /media/windrive-a under ubuntu OS.A little while back i decided to delete the mounting of the data partition and i fired command rm -r /media/windrive-a/. To give me a shock; all my data on data drive is gone.Now, I know this is not the command to remove mounted partition. But I have committed the wrong. Is there any way i can get my data back. These are very important data for me.

View 2 Replies View Related

Ubuntu :: On Update 293 Files Deleted

Jan 25, 2010

I did an update on one of my main computers last night. while in the update it reported "293 files to be REMOVED and 1 to be added".... it cranked away for some time and now all I get is a text login to my desktop. There is no graphics anymore. just a command line.

Is there any way to make it boot the way it used to or will I have to reinstall without formatting my hard drive (if so, how do I do this?)? I have checked and all my personal data is in tact. I was running Hardy Heron with 5.4 gigs of an 80 Gig HD free and 2 Gigs of RAM with an AMD 5000+ processor.

View 9 Replies View Related

Ubuntu :: Where Do Deleted Files Going After Using Nautilus

Mar 22, 2010

I use XBMC a lot and recenty i have been trying to download movies i have d/l using SABNZBDPLUS. I noticed my 320GB getting low so i tried deleting the files within the folder itself but got this message "Cannot move file to the deeted items folder, do you want to delete permanently?". Anyway i tried to delete but i guess it would not also the main folder had a lock icon on it.

So i read somewhere you can use nautilus in the terminal and once i navigated to the folder in question i pressed the delete key on my keyboard. The file is not in my trash can and i dont think is permenantly deleted as my disc space has not been reduced.

View 1 Replies View Related

Ubuntu :: Possible To Retrieve Deleted Files?

Oct 20, 2010

The question is simple. I had a FAT external pendrive with some thing of it, and I've stupidly shift-del eted 2 folders that now i needed. Could be possible to retrieve the deleted files?

View 5 Replies View Related

Programming :: Deleted Gawk And Now Nothing Will Configure?

Oct 27, 2010

So unbeknownst to me until today, but apparently all configure scripts rely on some version of awk to create the Makefile when config.status is run.how to get gawk reinstalled?I have compiled one on Ubuntu and copied it to my other machine but when run it throws the error:Code:./gawk: no such file or directorySo I am guessing I either need to create a static copy or maybe also copy the libs created from compile with it.

View 7 Replies View Related

Programming :: C++ Check If Pointer Is Deleted?

Apr 24, 2011

Is it possible to check if a pointer is deleted in C++ (using GDB)? For example:

Code:
a = new Thing();
b = a;
delete a;

// If all I have is the variable "b", how can I tell if it was deleted?

View 14 Replies View Related

Ubuntu Servers :: Logging - Record Password Attempts On Htaccess Files

Jul 22, 2010

After reading this pdf on top 5 things to log for security, ive decided to attempt this for my webserver. how i might setup some logging systems to do these tasks. Basic things i need to be able to do: Record things like password attempts on htaccess files, from what IP address, and how many attempts there were. Any useful links anyone can think of to get me started? Im a student programmer at university so any programming i should be able to cope fine.

View 2 Replies View Related

Debian :: Files Deleted But Process Open

Jun 4, 2015

My /dev/md1 is full

Code:

Select all# du -x -m --max-depth=1 | sort -n
shows
Code: Select all0   ./dev
0   ./proc
0   ./sys
1   ./home
1   ./lost+found

[Code] ....

There are files that have been deleted but open processes are still active. The result :

Code:
Select all# lsof | grep 'deleted'
shows
Code: Select allmysqld     2881      mysql    4u      REG                9,1          0     393317 /tmp/ib16UZEE (deleted)
mysqld     2881      mysql    5u      REG                9,1        798     393318 /tmp/ibqA5RvA (deleted)
mysqld     2881      mysql    6u      REG                9,1          0     393319 /tmp/ibfXpKmw (deleted)
mysqld     2881      mysql    7u      REG                9,1          0     393322 /tmp/ibcluSds (deleted)

[Code] ....

If I delete these files does it diminish the size of / var ? If yes, how to remove these and can I remove them ?

View 9 Replies View Related

Fedora :: Restoring Deleted Files On Ext4?

Jul 20, 2009

I have recently been helping my brother set up his computer with a fresh install of Fedora 11. Unfortunately things have not been going all that well. After having some problems with Fedora 11, such as it not liking his monitor and disabling Plymouth's graphical boot (I actually like to see what my systems doing!) things finally seemed to be going into place. Unfortunately the next day we were no longer able to log into his account. After hours of tweaking I finally found out it was that for some reason GNOME stopped liking his account.

This is where things went from bad to worse. I tired removing his own account and giving him a new one, unwittingly taking out his home directory in the process, all 80 gigabytes of it. And just as promised ext4 was extremely quick about it. What can I do to recover it? We have done similar things on NTFS on Windows XP, so I see no reason why a next-gen file-system like ext4 can't do it.

View 7 Replies View Related

OpenSUSE :: App For Recovering Deleted Files And Partitions?

Jun 18, 2011

A friend of mine had inportant files on his windows 7 PC. the pc took a virus, he took it with some "experts" wich happily DELTED the partition and reinstalled W7, and apps, WITHOUT backing up his files.

Ibe faced similar cases before, and on windows ibe used Recuva with mixed resutls, but. Is there an application in linux i can install on my opensuse 11.4 box to do the same task? Can you guys recommend good linux software (available for suse) that will do this? I read about "TestDisk", but ibe never used it.

View 9 Replies View Related

Ubuntu :: Recovering Deleted Files Of A Specific Name?

Mar 21, 2010

I need to get back two avi movie files but I've deleted hundreds and any recovery might try and drop them back on my small hard disk and overwhelm it! I know the files include the word 'Archer' but I'm using Formost, which is very easy to use, but it doesn't seem to allow for the searching of specific files by name. I can recover by type ie, avi, jpeg, pdf.....

Are there any recovery programs that will list files in a table so I can pick the ones I want to recover or do a search in Terminal for my 'Archer' files?

View 1 Replies View Related

Ubuntu :: Program To Recover Deleted Files

Jul 6, 2010

Deleted a whole bunch of files, I have backed it up but it was from about 2 weeks ago and as I had added loads of stuff in the meantime I urgently need to recover the files.Ubuntu 9.10. Any and every file recovery program you know please.Preferably one that allows me to recover an entire directory, not just individual files, but it'll be fine if that is it.

View 9 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved