Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

What if the position is not at 512 but at 512G?


Not tested, by I think the performance will be in the same order. Would be nice to do a benchmark test.


No, it is O(n) vs O(1). Why would you read 512G + 512 bytes if you only need to read 512 bytes at offset 512G?


I think you can just invert and do tail first

sudo tail -zc +513 /dev/sda | head -c 512 > /tmp/boot.2


Well now you're seeking to the offset (tail is).




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: