LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-01-2017, 11:30 PM   #16
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: CentOS
Posts: 4,362

Rep: Reputation: 2001Reputation: 2001Reputation: 2001Reputation: 2001Reputation: 2001Reputation: 2001Reputation: 2001Reputation: 2001Reputation: 2001Reputation: 2001Reputation: 2001

Quote:
Originally Posted by John VV View Post
that is why i like " srm "
Code:
 srm -h
Usage: srm [OPTION]... [FILE]...
Overwrite and remove (unlink) the files. By default use the 35-pass Gutmann
method to overwrite files.

  -d, --directory       ignored (for compatability with rm(1))
  -f, --force           ignore nonexistant files, never prompt
  -i, --interactive     prompt before any removal
  -x, --one-file-system do not cross file system boundaries
  -s, --simple          overwrite with single pass using 0x00 (default)
  -P, --openbsd         overwrite with three passes like OpenBSD rm
  -D, --dod             overwrite with 7 US DoD compliant passes
  -E, --doe             overwrite with 3 US DoE compliant passes
  -G, --gutmann         overwrite with 35-pass Gutmann method
  -C, --rcmp            overwrite with Royal Canadian Mounted Police passes
  -r, -R, --recursive   remove the contents of directories
  -v, --verbose         explain what is being done
  -h, --help            display this help and exit
  -V, --version         display version information and exit

---------
Just don't use in on an SSD. Those overwrites accomplish nothing but needless wear on the device.
 
Old 03-03-2017, 06:24 AM   #17
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.10, Centos 7.5
Posts: 17,707

Rep: Reputation: 2497Reputation: 2497Reputation: 2497Reputation: 2497Reputation: 2497Reputation: 2497Reputation: 2497Reputation: 2497Reputation: 2497Reputation: 2497Reputation: 2497
I like Post #7 ; the sort of definitive thing I'd use for eg getting rid of 'impossibly named' files

Of course, you might want to make a note of the ownerships+perms before deleting it ...
 
Old 03-06-2017, 08:43 AM   #18
jr_bob_dobbs
Member
 
Registered: Mar 2009
Distribution: Slackware, Linux From Scratch, Bedrock
Posts: 422

Original Poster
Blog Entries: 56

Rep: Reputation: 60
Quote:
Originally Posted by hydrurga View Post
If you're using Bash:

shopt -s dotglob

ensures that the * glob will subsequently match both unhidden and hidden files.
This worked, and is simple. Made some interesting man page reading, thank you. (yes, I use bash)
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Bash hides current directory Asinine Slackware 2 09-13-2009 04:32 AM
Bash, deleting only files in a directory tree? jon_k Programming 4 05-13-2007 12:36 PM
Bash Expression: Current Directory & All Subdirectories Below gmcauley Programming 2 01-01-2007 03:36 PM
setting bash to look in current directory before searching the path muhkuhmasta Linux - Newbie 4 09-21-2004 03:08 AM
BASH: How to get current workin directory? gmitra Programming 9 09-20-2003 11:30 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:51 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration