Sponsored Content
Top Forums Shell Programming and Scripting find restricted search to some directories Post 302484771 by m69w on Monday 3rd of January 2011 06:38:27 AM
Old 01-03-2011
Thanks Radoulov, your explanation makes sense. Would some output be expected with the following set then ?

./201012/a/X01012/X
./201012/a/201012/Y
./201011/a/b/201011/Z
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

script to search all the directories

Hi there, Is there any command or script to search all the directories for duplicated files? Thanks, Abrahim (3 Replies)
Discussion started by: abk
3 Replies

2. Shell Programming and Scripting

how to search directories

Hello everybody, i'm dummy for unix but i want to learn something. i want to search the working directory and its subdirectories( all ) to find the files which are more than 1024 bytes. So which commands must i learn? Thanks to all. (13 Replies)
Discussion started by: redbeard_06
13 Replies

3. Shell Programming and Scripting

How to search through directories and sub dir

Im working on a project that basically imitates the find and whereis commands. The program will take in a file name or regular expression and, starting with the current directory search downwards and match any files with that pattern and prints the path name. I don't understand how to do this... (5 Replies)
Discussion started by: new2C
5 Replies

4. UNIX for Dummies Questions & Answers

Using "find" in restricted directories

Hi, I would like to know is there any way to find/search filenames or directories inside the directories which has resticted permission. When we use normal "find" command it returns "permission denied" message for the root directories or directories with restricted permissions. Thanks (2 Replies)
Discussion started by: forstudy3
2 Replies

5. Shell Programming and Scripting

How to find 777 permisson is there or not for Directories and sub-directories

Hi All, I am Oracle Apps Tech guy, I have a requirement to find 777 permission is there or not for all Folders and Sub-folders Under APPL_TOP (Folder/directory) with below conditions i) the directory names should start with xx..... (like xxau,xxcfi,xxcca...etc) and exclude the directory... (11 Replies)
Discussion started by: gagan4599
11 Replies

6. UNIX for Dummies Questions & Answers

Using grep command to find the pattern of text in all directories and sub-directories.

Hi all, Using grep command, i want to find the pattern of text in all directories and sub-directories. e.g: if i want to search for a pattern named "parmeter", i used the command grep -i "param" ../* is this correct? (1 Reply)
Discussion started by: vinothrajan55
1 Replies

7. UNIX for Advanced & Expert Users

Search file in all directories.

Hi colleagues, I need to search one file in all dierctories, i have O.S. AIX 5.3, my file began with cc, the others caracters i unknow. Then i can to search one string in file in all dierctories. Thank you for advanced. (8 Replies)
Discussion started by: systemoper
8 Replies

8. Shell Programming and Scripting

Search for file extensions in the given directories

Hey guys, I'm lost... I need to make a script that will work in this way: ./script.sh -e sh /usr/bin /home/student this script will result in this output: amuFormat.sh /usr/bin gettext.sh /urs/bin perfect.sh /home/student the parameter -e <ext> gives you which... (2 Replies)
Discussion started by: Miki1579
2 Replies

9. Shell Programming and Scripting

Search: find current line, then search back

Hello. I want to find a line that has "new = 0" in it, then search back based on field $4 () in the current line, and find the first line that has field $4 and "last fetch" Grep or Awk preferred. Here is what the data looks like: 2013-12-12 12:10:30,117 TRACE last fetch: Thu Dec 12... (7 Replies)
Discussion started by: JimBurns
7 Replies

10. UNIX for Beginners Questions & Answers

How to use a grep search to search for a specific string within multiple directories?

Lets say I have a massive directory which is filled with other directories all filled with different c++ scripts and I want a listing of all the scripts that contain the string: "this string". Is there a way to use a grep search for that? I tried: grep -lr "this string" * but I do not... (3 Replies)
Discussion started by: Circuits
3 Replies
scsi_ext_sense_fields(9F)				   Kernel Functions for Drivers 				 scsi_ext_sense_fields(9F)

NAME
scsi_ext_sense_fields, scsi_sense_info_uint64, scsi_sense_cmdspecific_uint64 - retrieve fields from SCSI sense data SYNOPSIS
#include <sys/scsi/scsi.h> void scsi_ext_sense_fields(uint8_t *sense_buffer, int *sense_buf_len, uint8_t **information, uint8_t **cmd_spec_info, uint8_t **fru_code, uint8_t **sk_specific, uint8_t **stream_flags); boolean_t scsi_sense_info_uint64(uint8_t *sense_buffer, int sense_buf_len, uint64_t *information); boolean_t scsi_sense_cmdspecific_uint64(uint8_t *sense_buffer, int sense_buf_len, uint64_t *cmd_spec_info); INTERFACE LEVEL
Solaris DDI specific (Solaris DDI). PARAMETERS
sense_buffer Pointer to a buffer containing SCSI sense data. The sense data is expected in wire format starting at the response code. It can be in either a fixed or descriptor format. information For scsi_ext_sense_fields(), this is a call-by-reference pointer to uint8_t. A pointer to the INFORMATION field in the sense data may be returned in this parameter. The scsi_sense_info_uint64() function requires a pointer to uint64_t. The data in the information field is returned as a 64 bit integer. If the sense data information field is 32 bits, fixed format, the most significant 32-bits are 0. cmd_spec_info For scsi_ext_sense_fields(), this is a call-by-reference pointer to uint8_t. A pointer to the COMMAND_SPECIFIC INFORMATION field in the sense data can be returned in this parameter. The scsi_sense_cmdspecific_uint64() function requires a pointer to uint64_t. The data in the command specific information field is returned as a 64 bit integer. If the sense data command specific information field is 32 bits, fixed format, the most significant 32-bits are 0. fru_code Call-by-reference pointer to uint8_t. A pointer to the FIELD REPLACEABLE UNIT CODE field in the sense data can be returned in this parameter. sk_specific Call-by-reference pointer to uint8_t. A pointer to the SENSE KEY SPECIFIC field in the sense data can be returned in this parameter. stream_flags Call-by-reference pointer to uint8_t. A pointer to the byte containing the ILI, EOM, and FILEMARK flags can be returned in this parameter. DESCRIPTION
The scsi_ext_sense_fields() function can be used to retrieve any of the extended sense data fields from a sense data buffer, regardless of whether the sense data is in fixed format or in descriptor format. The information, cmd_spec_info, fru_code, sk_specific, and stream_specific parameters are all call-by-reference output parameters. Each parameter corresponds to one or more of the extended sense data fields. Any of these parameters can be passed as NULL if the caller is not interested in the associated data. If the requested data is present and valid for each output parameter, the pointer passed in is set to point to the relevant location in the sense buffer. If the data is not present or invalid, the pointer is set to NULL. For example, a caller that requests a pointer to the information field would get NULL when an information descriptor is not present for descriptor format sense data or when the valid bit is not set for fixed format sense data. The information and command specific information fields can be 4 bytes or 8 bytes in length, depending on whether the sense data is in fixed or descriptor format respectively. Drivers can use scsi_validate_sense(9F) to determine the sense data format and, by extension, the length of the information and command specific information fields. A driver can determine whether integer data is included in the information or command specific information fields based on the asc and ascq sense keys, such as the LBA of a failed disk request. The scsi_sense_info_uint64() function retrieves the contents of the information field as a 64 bit integer and the scsi_sense_cmdspecific_uint64() retrieves the command specific information field as a 64 bit integer. Drivers should use scsi_validate_sense(9F) to ensure that the sense buffer contains valid sense data. RETURN VALUES
The scsi_sense_info_uint64() function returns TRUE if the information field is present and valid. Otherwise it returns FALSE. The scsi_sense_cmdspecific_uint64() function returns TRUE if the command specific information field is present and valid. Otherwise it returns FALSE. CONTEXT
The scsi_ext_sense_fields(), scsi_sense_info_uint64() and scsi_sense_cmdspecific_uint64()() functions can be called from user or interrupt context. SEE ALSO
scsi_find_sense_descr(9F), scsi_sense_asc(9F), scsi_sense_ascq(9F), scsi_sense_key(9F), scsi_validate_sense(9F) SunOS 5.11 29 Jun 2006 scsi_ext_sense_fields(9F)
All times are GMT -4. The time now is 08:07 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy