Hello all
I wander if I make for example " ls -l "
And it gives me all the files in the directory with the additional info like data size and privileges
But what if I like to filter the stout result for example by date
When I try to do:
echo "`ls -l`" | grep "Jan 12"
it gives me the... (2 Replies)
Hi,
I'm newbie to Unix. I'd like to count the total size of those files in my directory by date. For example, files on this period 05/01/08 - 05/31/08. If possible can we count by byte instead of kb.
if I use $ du - ks , it will add up all files in the dir.
thanks,
Helen (5 Replies)
Hi guys.
I am trying, to move files found with the find command...
Script runs fine, until it reaches a file that contains spaces...
Here is what i wrote up quickly.
ROOTDIR=/apps/data
SEARCH=$(find /data/HDTMPRestore/home/tmq/ -type f -print | grep Mods/Input/bck | cut -c19-)
for i... (1 Reply)
im a beginner in shell scripting and i need a script which will find a file in a given path without the use of find or grep command.......i need some kind of code.....plzzz plzzzz help me......ive tried n searched every where but i couldn't find the solution for my particular problem..... (4 Replies)
Hi,
I want to find the size of the files added to a folder after a certain date(say 1st of october), I know we can list the files which were created after a certain date , but is there anyway to find the total size of those files ? (3 Replies)
Hi,
Could anyone help me to solve this problem?
I have two files "f1" and "f2" having 2 fields in each, a) file size and b) file name. The data are almost same in both the files except for few and new additional lines. Now, I have to find out and print the output as, the difference in the... (3 Replies)
Hi!
I want to find duplicate files (criteria: file size) in my download folder.
I try it like this:
find /Users/frodo/Downloads \! -type d -exec du {} \; | sort > /Users/frodo/Desktop/duplicates_1.txt;
cut -f 1 /Users/frodo/Desktop/duplicates_1.txt | uniq -d | grep -hif -... (9 Replies)
If I have a number of files in a directory, for example,
test.1
test.2
test.3
abc.1
abc.2
abc.3
and I need to find the total file size of all of the test.* files, I can use du -bc test.* in Linux.
However, in Solaris, du does not have the -c option. What can I do in Solaris to get... (11 Replies)
Hi,
How would you write bash script that given a directory as an argument and finds all duplicate files (with same contents - by using bytewise comparison) there and prints their names? (6 Replies)
Discussion started by: elior
6 Replies
LEARN ABOUT LINUX
scsi_setup_cdb
scsi_setup_cdb(9F) Kernel Functions for Drivers scsi_setup_cdb(9F)NAME
scsi_setup_cdb - setup SCSI command descriptor block (CDB)
SYNOPSIS
int scsi_setup_cdb(union scsi_cdb *cdbp, uchar_t cmd, uint_t addr, uint_t cnt, uint_t othr_cdb_data);
INTERFACE LEVEL
Solaris DDI specific (Solaris DDI).
PARAMETERS
cdbp Pointer to command descriptor block.
cmd The first byte of the SCSI group 0, 1, 2, 4, or 5 CDB.
addr Pointer to the location of the data.
cnt Data transfer length in units defined by the SCSI device type. For sequential devices cnt is the number of bytes. For
block devices, cnt is the number of blocks.
othr_cdb_data Additional CDB data.
DESCRIPTION
scsi_setup_cdb() function initializes a group 0, 1, 2, 4, or 5 type of command descriptor block pointed to by cdbp using cmd, addr, cnt,
othr_cdb_data.
addr should be set to 0 for commands having no addressing information (for example, group 0 READ command for sequential access devices).
othr_cdb_data should be additional CDB data for Group 4 commands; otherwise, it should be set to 0.
scsi_setup_cdb() function does not set the LUN bits in CDB[1] as the makecom(9F) functions do. Also, the fixed bit for sequential access
device commands is not set.
RETURN VALUES
scsi_setup_cdb() returns:
1 Upon success.
0 Upon failure.
CONTEXT
These functions can be called from a user or interrupt context.
SEE ALSO makecom(9F), scsi_pkt(9S)
Writing Device Drivers
American National Standard Small Computer System Interface-2 (SCSI-2)
American National Standard SCSI-3 Primary Commands (SPC)
SunOS 5.10 23 Jun 1997 scsi_setup_cdb(9F)