Thai Nguyen wrote: > Thank you for replying, > > I see your good suggestion by using lseek, but I still don’t know how to use > it to calculate these LBAs in OpenSolarisX system file. > > The following function that I am trying to port to OpenSolarisX ZFS is > finding a range of start and end physical unit LBAs by given file and its > offset bytes. I call send you this function codes, it is about more one > paper page long. > > void TWL_File_LBA::get_unit_lba_range(char *file_name, > ULONGLONG byte_offset, > ULONGLONG record_length, > ULONGLONG &range_start_unit_lba, > ULONGLONG &range_end_unit_lba, > ULONGLONG &run_length)
That makes no sense at all with ZFS, files aren't written like that in consecutive chunks of disk storage. What does the program you are trying to port do with this data ? What does the program actually do ? The reason I ask is so we can up level this from a low level functions that exist on Linux but not on Solaris and try and help you with the actual problem you are trying to solve. -- Darren J Moffat _______________________________________________ opensolaris-code mailing list [email protected] http://mail.opensolaris.org/mailman/listinfo/opensolaris-code
