Let me tell you something from my l'il experience... while using commands like the recursive removal .... yeah especially data removal commands, please check with manual options 1-2 times.... you might be knowing it already if you've tested this experimental directory removal.... it won't ask you again, 'Should I remove it?', but it will do the removal process assuming that the person who gave this command is well aware of it's consequences! ... you can explore to various commands and their options by typing...
Hi,
I look for a script to create 150 directories :
d000
d001
d002
...
...
d149
would you help me please ?
I think it would be
for i
mkdir d$i
Many thanks.
PS :
#uname -a
AIX fserver 3 5 0050691A4C00 (2 Replies)
Is there ant way to increase max number of folders in the directory from the 32766:
Problem UFS:
shell>mkdir mmm
mkdir: mmm: Too many links
But there are no links, just folders.
shell>ls | wc -l
32766 (3 Replies)
I am having trouble using cp and mkdir commands on a small script. The problem is I have spaces what I am trying to mkdir and then copy. Any suggestions on how I can solve this problem? I've tried searching online.
while read linefile
do
echo mkdir -p $CPP$linefile | cut -d / -f 1-5,8-12
... (10 Replies)
Hi, please help me with this small script
#!/bin/sh
curdir=`pwd`
n20=$curdir'/n20/'
msat=$curdir'/n20/msat/'
if
then
mkdir $n20
fi
if
then
mkdir $msat
fi
for a in 30 40 50 60 70 80
do (4 Replies)
Hi, Unix Gurus,
- I have a simple question, I need create multiple directory. I use
mkdir {dir1, dir2, dir3)
I got one directory as
{dir1, dir2, dir3}
I searched @ google, I got answer as above code.:wall::confused:
Anybody has any idea
Thanks in advance
---------- Post updated... (3 Replies)
Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted!
1. The problem statement, all variables and given/known data:
Do the procedure, which if there are 5 parameters then it creates 4 directories with names of 4 parameters, in... (2 Replies)
hi linux expert
what is a difference between:
mkdir test and mkdir ./test
and also
if ( -e /test ) then and if ( -e ./test ) then
thanks in advance
Please use icode or code tags next time for your code and data (1 Reply)
Importing images from a camera (or two).
I sort by date (1901 this month).
Currently (failing)
if ]
then
echo "Found Panasonic G9X"
#echo "List files on camera"
#ls ${pana}/*
. chxdir.sh ${photos}/$mn
I want to change directory to a fixed base ($photos)/$mn... (10 Replies)
Discussion started by: dpawson
10 Replies
LEARN ABOUT SUSE
sg_prevent
SG_PREVENT(8) SG3_UTILS SG_PREVENT(8)NAME
sg_prevent - sends a SCSI PREVENT ALLOW MEDIUM REMOVAL command
SYNOPSIS
sg_prevent [--allow] [--help] [--prevent=PC] [--verbose] [--version] DEVICE
DESCRIPTION
Sends a SCSI PREVENT ALLOW MEDIUM REMOVAL command to DEVICE. The default action of this utility is to prevent the removing or ejecting of
the medium from a drive. This is done by ignoring the SCSI START STOP UNIT command (see sg_start) and ignoring the eject button on the
drive when the user presses it. Drives that hold removable disks, tape cartridges or cd/dvd media typically implement this command. The
definition of the "prevent" codes for this command differ between disks and tapes (covered by SBC-3 and SSC-3) and cd/dvd drives (covered
by MMC-5). The "prevent codes" described here are from MMC-5.
OPTIONS
Arguments to long options are mandatory for short options as well.
-a, --allow
allow medium removal. This is equivalent to setting to '--prevent=2'. Cannot be used with --prevent=PC option (i.e. either use no
options (hence prevent removal), this option or --prevent=PC).
-h, --help
output the usage message then exit.
-p, --prevent=PC
where PC is a prevent code value. Defined values are: 0 allows removal, 1 prevents removal (default), 2 allows persistent removal
while 3 prevents persistent removal. "Persistent" in this context means that the initiator (port) that successfully uses code 3
blocks other initiators (ports) from allowing removal. A "persistent prevent" state can be cleared by the owner allowing persistent
removal (code 2) or a power cycle (or anything that resets the device (lun)) or some special commands (e.g. various service actions
of Persistent Reserve Out, see SPC-3).
-v, --verbose
increase the level of verbosity, (i.e. debug output).
-V, --version
print the version string and then exit.
EXIT STATUS
The exit status of sg_prevent is 0 when it is successful. Otherwise see the sg3_utils(8) man page.
AUTHORS
Written by Douglas Gilbert.
REPORTING BUGS
Report bugs to <dgilbert at interlog dot com>.
COPYRIGHT
Copyright (C) 2004-2007 Douglas Gilbert
This software is distributed under a FreeBSD license. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PUR-
POSE.
SEE ALSO
sg_start(sg3_utils), sg_persist(sg3_utils)
sg3_utils-1.23 January 2007 SG_PREVENT(8)