Is there any error message? Are you sure that the directory contains files or other directories? Because ls won't display anything that isn't there. You can test it with this:
I have a Solaris 8 Ultra 1 on my network that we use as a utility server.
The last command, which looks in the /var/adm/wtmpx file, is not working.
When I do a last, the latest entry is dated June 3, but the /var/adm/wtmpx file is dated whenever a login is successful (verified by typing a... (3 Replies)
The below is a simple script, but doesnt work.
#!/bin/ksh
cat <<XYZ
-h help
-T Test (required)
-D Develop (required)
XYZ
Help is appreciated (5 Replies)
Hi Guys,
I have about 12000 files in a folder and I want to copy these to another folder. I am using the cp command to do this but it errors out saying cp -- argument list too long.
Is there any way to get around this?
I don't want to do a mv but use only cp.
Thanks (9 Replies)
I have three files a.txt , b.txt , c.txt in a directory called my_dir1 .These files were created before two or three months . I have a tar file called my_tar1.tar which contains three files a.txt , b.txt , d.txt . Somebody untarred the my_tar1.tar into my_dir1 directory. So existing two files were... (1 Reply)
Hi everyone,
when executing this command in unix:
echo "WM7 Fatal Alerts:", $(cat query1.txt) > a.csvIt works fine, but running this command in a shell script gives an error saying that there's a syntax error.
here is content of my script:
tdbsrvr$ vi hc.sh
"hc.sh" 22 lines, 509... (4 Replies)
Hello.
I would like to ask your help regarding the cp command. We are using a cp command to create a back-up copy of our file but to no avail. It's just not working. We already checked the file and directory permissions and all seems correct.
We have a script (ftp.script) which calls on... (1 Reply)
Hi All,
I am trying to select 30 days older files under current directory ,but not from subdirectory using below command.
find <Dir> -type f -mtime + 30
This command selecting all the files from current directory and also from sub directory .
I read some documention through internet ,... (1 Reply)
Hi everyone
I have a problem with my script
If I try directly this command
/usr/bin/nice -n 19 mysqldump -u root --password="******" wiki_schneider -c | nice -n 19 gzip -9 > /point_de_montage/$(date '+%Y%m%d')-wiki-db.sql.gz
It works
But if I simply add this command in a script and... (8 Replies)
Hello i am having an issue with bash script and this is the code
now=$(cat hosts1.txt | awk '{print $2;}')
while read n ;do
ssh root@$now 'useradd test1; echo -e "test1\ntest1" | passwd test1 && echo "test1 ALL=(ALL:ALL) ALL" >> /etc/sudoers'
When i execute only part with cat, it... (8 Replies)
Discussion started by: tomislav91
8 Replies
LEARN ABOUT X11R4
nisrmdir
nisrmdir(1) User Commands nisrmdir(1)NAME
nisrmdir - remove NIS+ directories
SYNOPSIS
nisrmdir [-if] [-s hostname] dirname
DESCRIPTION
nisrmdir deletes existing NIS+ subdirectories. It can remove a directory outright, or simply remove replicas from serving a directory.
This command modifies the object that describes the directory dirname, and then notifies each replica to remove the directory named
dirname. If the notification of any of the affected replicas fails, the directory object is returned to its original state unless the -f
option is present.
This command will fail if the NIS+ master server is not running.
OPTIONS
The following options are supported:
-i Interactive mode. Like the system rm(1) command the nisrmdir command will ask for confirmation prior to removing a direc-
tory. If the name specified by dirname is a non-fully qualified name this option is forced on. This prevents the removal of
unexpected directories.
-f Force the command to succeed even though it may not be able to contact the affected replicas. This option should be used
when a replica is known to be down and will not be able to respond to the removal notification. When the replica is finally
rebooted it will read the updated directory object, note that it is no longer a replica for that directory, and stop
responding to lookups on that directory. Cleanup of the files that held the now removed directory can be accomplished manu-
ally by removing the appropriate files in the /var/nis directory. See nisfiles(4) for more information.
-s hostname Specify that the host hostname should be removed as a replica for the directory named dirname. If this option is not
present all replicas and the master server for a directory are removed and the directory is removed from the namespace.
Special per-server and per-directory access restrictions may apply when this command updates the serving lists of the affected NIS+
servers. For more information, see nisopaccess(1).
OPERANDS
The following operand is supported:
dirname An existing NIS+ directory.
EXAMPLES
Example 1: Using the nisrmdir Command
To remove a directory bar under the foo.com. domain, one would use the command:
example% nisrmdir bar.foo.com.
To remove a replica that is serving directory bar.foo.com. one would use the command:
example% nisrmdir -s replica.foo.com. bar.foo.com.
To force the removal of directory bar.foo.com. from the namespace, one would use the command:
example% nisrmdir -f bar.foo.com.
ENVIRONMENT VARIABLES
NIS_PATH If this variable is set, and the NIS+ directory name is not fully qualified, each directory specified will be searched
until the directory is found. See nisdefaults(1).
EXIT STATUS
The following exit values are returned:
0 Successful operation.
1 Operation failed.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWnisu |
+-----------------------------+-----------------------------+
SEE ALSO
nis+(1), nisdefaults(1), nisopaccess(1),nisrm(1), nisfiles(4), attributes(5)NOTES
NIS+ might not be supported in future releases of the SolarisTM Operating Environment. Tools to aid the migration from NIS+ to LDAP are
available in the Solaris 9 operating environment. For more information, visit http://www.sun.com/directory/nisplus/transition.html.
SunOS 5.10 10 Dec 2001 nisrmdir(1)