Logged on yesterday no problem. Running Win 7 64 bit. Nothing has changed on my system overnight. Now the launcher is stuck 'Retrieving content list from Akamai' My wife's computer on same wired network can log in no problem. I've tried rebooting and updating virus protection and at a loss as to what to try next.
On a Linux desktop (RHEL4) I want to extract a range of bytes (typically less than 1000) from within a large file (>1 Gig). I know the offset into the file and the size of the chunk.
I can write code to do this but is there a command line solution?
Ideally, something like:
DanMDanM1,42611 gold badge1313 silver badges1414 bronze badges
5 Answers
kenorb76k3333 gold badges434434 silver badges452452 bronze badges
Thomas Padron-McCarthyThomas Padron-McCarthy23.3k55 gold badges4343 silver badges7171 bronze badges
This is an old question, but I'd like to add another version of the
dd
command that is better-suited for large chunks of bytes:where
$offset
and $bytes
are numbers in byte units.The difference with Thomas's accepted answer is that
bs=1
does not appear here. bs=1
produces the input and output block size to be 1 byte, which makes it terribly slow when the number of bytes to extract is large.ChronoTriggerChronoTrigger
The dd command can do all of this. Look at the seek and/or skip parameters as part of the call.
JoeJoe32.5k1414 gold badges9090 silver badges107107 bronze badges
head
+ tail
Not sure how it compare to
dd
in efficiency, but it is fun:picks 3 bytes, starting at the 2nd one:
See also: https://stackoverflow.com/a/1272995/895245
Community♦
Ciro Santilli 新疆改造中心996ICU六四事件Ciro Santilli 新疆改造中心996ICU六四事件158k3535 gold badges595595 silver badges499499 bronze badges
Albert BurbeaAlbert Burbea