I have a TAR (compressed) file that I uncompressed using the following command
$ tar xvf uagent.tar
It created a directory structure as follows
<root>/arcagent/UAGENT/reloc/$UAGENT_HOME/
How do I access files under the $UAGENT_HOME? Every time I do change directory command, the OS... (3 Replies)
The script below was written to select files and convert a particular string to something other and replace that file. However, I came across some issues with filenames that contain spaces, any suggestions to get around this? Any other suggestions that may apply to this code would also be... (5 Replies)
Hi, I know that inode for each file is unique, but is it the for the directory? So far I found different directories has the same inode nubmer when you do ls -i, could some one explain why? Thanks a lot. (9 Replies)
I need help writing a bash script for the windows cygwin environment. I'm not sure if bash is the optimal tool. Perhaps perl would be better? Either would work.
I have directories whose names include the date they were created. The directory names are in the format of... (0 Replies)
Sun Solaris Unix Question
Haven't been able to find any solution for this situation. Let's just say the file names listed below exist in a directory. I want the find command to find all files in this directory but at the same time I want to eliminate certain file names or files with certain... (2 Replies)
hai,
I am new to Unix, I have a requirement to display owner name , directory or sub directory name, who's owner name is not equal to "oasitqtc".
(here "oasitqtc" is the owner of the directory or sub directory.)
i have a command (below) which will display all folders and sub folders, but i... (6 Replies)
I am trying to loop through folders and extract the name of the lowest level subfolder
I was running the script below, it returns
/bb/bin/prd/newyork
/bb/bin/prd/london
/bb/bin/prd/tokyo
I really want
newyork
london
tokyo
I couldn't find a standard variable for the lowest level... (1 Reply)
Hi guys,
I have lots of files that look like:
ABC.packed.dir
DEF.packed.dir
GHI.packed.dir
etc...
I would like them to have more of the usual naming convention
ABC
DEF
GHI
etc...
so I was thinking that I could: (2 Replies)
Some guidance is highly appreciated.
I have 10 directories with names ending with 'xyz', each of them have about 30000 files. I want to loop through the contents of each directory and produce a single output per directory. So I want to have 10 output files named 'directory_name'_out.
With... (1 Reply)
Discussion started by: newbie83
1 Replies
LEARN ABOUT SUNOS
ttysrch
ttysrch(4) File Formats ttysrch(4)NAME
ttysrch - directory search list for ttyname
DESCRIPTION
ttysrch is an optional file that is used by the ttyname library routine. This file contains the names of directories in /dev that contain
terminal and terminal-related device files. The purpose of this file is to improve the performance of ttyname by indicating which subdirec-
tories in /dev contain terminal-related device files and should be searched first. These subdirectory names must appear on separate lines
and must begin with /dev. Those path names that do not begin with /dev will be ignored and a warning will be sent to the console. Blank
lines (lines containing only white space) and lines beginning with the comment character "#" will be ignored. For each file listed (except
for the special entry /dev), ttyname will recursively search through subdirectories looking for a match. If /dev appears in the ttysrch
file, the /dev directory itself will be searched but there will not be a recursive search through its subdirectories.
When ttyname searches through the device files, it tries to find a file whose major/minor device number, file system identifier, and inode
number match that of the file descriptor it was given as an argument. If a match is not found, it will settle for a match of just
major/minor device and file system identifier, if one can be found. However, if the file descriptor is associated with a cloned device,
this algorithm does not work efficiently because the inode number of the device file associated with a clonable device will never match
the inode number of the file descriptor that was returned by the open of that clonable device. To help with these situations, entries can
be put into the /etc/ttysrch file to improve performance when cloned devices are used as terminals on a system (for example, for remote
login). However, this is only useful if the minor devices related to a cloned device are put into a subdirectory. (It is important to note
that device files need not exist for cloned devices and if that is the case, ttyname will eventually fail.) An optional second field is
used in the /etc/ttysrch file to indicate the matching criteria. This field is separated by white space (any combination of blanks or
tabs). The letter M means major/minor device number, F means file system identifier, and I means inode number. If this field is not speci-
fied for an entry, the default is MFI which means try to match on all three. For cloned devices the field should be MF, which indicates
that it is not necessary to match on the inode number.
Without the /etc/ttysrch file, ttyname will search the /dev directory by first looking in the directories /dev/term, /dev/pts, and /dev/xt.
If a system has terminal devices installed in directories other than these, it may help performance if the ttysrch file is created and con-
tains that list of directories.
EXAMPLES
Example 1: A sample display of /etc/ttysrch command.
A sample /etc/ttysrch file follows:
/dev/term MFI
/dev/pts MFI
/dev/xt MFI
/dev/slan MF
This file tells ttyname that it should first search through those directories listed and that when searching through the /dev/slan direc-
tory, if a file is encountered whose major/minor devices and file system identifier match that of the file descriptor argument to ttyname,
this device name should be considered a match.
FILES
/etc/ttysrch
SEE ALSO ttyname(3C)SunOS 5.10 23 Feb 1994 ttysrch(4)