Identifying file associated with a bad sector on ext2/ext3/ext4

Monday, April 16, 2018

I got some SMART warnings about a bad sector on my hard drive, and I wanted to know which specific file had the bad sector.

First, I looked at the SMART logs to see where the problem was:

# smartctl -x /dev/sdd

  After command completion occurred, registers were:
  -- -- -- == -- == == == -- -- -- -- --
  40 -- 51 00 08 00 00 04 4b 5b c0 40 00  Error: UNC at LBA = 0x044b5bc0 = 72047552


fdisk -l is useful for looking at the partition info and sector size:

# fdisk -l /dev/sdd
Disk /dev/sdd: 1.8 TiB, 2000398934016 bytes, 3907029168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x54afc7e9

Device     Boot Start        End    Sectors  Size Id Type
/dev/sdd1        2048 3907029167 3907027120  1.8T 83 Linux

Then I used badblocks to look around that physical sector for more bad sectors. My sector size is 512 bytes, shown above; also, badblocks takes the end sector number first, followed by the start sector:

# badblocks -b 512 /dev/sdd 72047570 72047540

Finally, debugfs is useful for finding which files are on those blocks.


  1. First, find the logical filesystem block number by computing (physical sector - partition start sector) * (physical sector size / filesystem block size). In my case, this would be (72047552 − 2048) * (512 / 4096) = 9005688. Since there are 9 contiguous sectors affected, the bad area stretches into block 9005689 as well.
  2. Use testb to see whether there is actually anything there. If not, then no data is lost.
  3. Use icheck to find the inode corresponding to those blocks. Luckily (?), both bad blocks are associated with the same inode here.
  4. Finally, use ncheck to find the pathname(s) associated with the inode.
# debugfs /dev/sdd1
debugfs 1.43.5 (04-Aug-2017)
debugfs:  testb 9005688
Block 9005688 marked in use
debugfs:  testb 9005689
Block 9005689 marked in use
debugfs:  icheck 9005688
Block   Inode number
9005688 105518423
debugfs:  icheck 9005689
Block   Inode number
9005689 105518423
debugfs:  ncheck 105518423
Inode   Pathname
105518423       /drz/rdiff-backup/artanis/var/lib/pgsql/data/base/21595/26720

Here, it was just a backup file, so once I swap out the hard drive or reallocate the sector, the next backup cycle will fix the lost data.

Tags: linux | Posted at 22:57 | Comments (6)


RitaLix on Thursday, June 13, 2019 at 04:14

Юлия Мирославовна Чекарева из Харькова, тел +380957168219 – ужасный человек, ее нельзя подпускать к детям на пушечный выстрел! Я имела печальный опыт, пригласив ее к своей дочке, и теперь зареклась от всяких нянь. Быть может, есть и хорошие, но то, что она сделала с моим ребенком, надолго оставило психологическую травму. Теперь нужна помощь психолога, после многочисленных унижений, даже избиений. Я сразу не поверила, как можно ударить трехлетнюю малышку, думала, что это фантазия ребенка. Оказалась правда, для чего пришлось взять напрокат камеру. Вы знаете, это нечто, как только я уходила из квартиры, Юля сразу же начинала орать на дочь, требовать, чтобы сидела на стуле и не мешала ей говорить по телефону. Кормление сводилось к – процитирую: Жри, что дают! При увольнении имела наглость заявить, что я, мать, избаловала своего ребенка!

CraigAbary on Thursday, June 13, 2019 at 08:58

good christian dating service women forced suck cock over 50 and dating
how to ask on line date to stop online dating when dating a hispanic girl
free dating site south florida not to do when dating a girl
best dating apps kolkata curvy bbw hookup dating sites free
what is the best free dating site for louisiana dating apps for hooking up

NetgamesdTeark on Thursday, June 13, 2019 at 09:41

RosaLix on Thursday, June 13, 2019 at 17:47

Мы - состоятельные по украинским меркам родители, и готовы платить немало, надеясь, что наше любимое чадо под присмотром и в полном порядке.
Юлия Линченко или как она сейчас Чекарева 16.06.1978гр, тел +380957168219, нам это обещала, произведя поначалу приятное впечатление. Деловитая, активная, быстро нашла общий язык с малышом, прямо находка! Однако через какое-то время ребенок стал замкнут, он не хотел видеть эту «няню» и реально ее боялся. На вопросы малыш не отвечал, пришлось поставить камеру в квартире.
Увиденное привело нас в шок. Юля заставила малыша раздеться, потом это сделала сама, и предложила странную игру с ребенком, трогать друг друга за разные места. В том числе интимные.

Jamesgrext on Thursday, June 13, 2019 at 22:42

ieo exchange
Cryptocurrency exchange idax earlier launched its first token, Ampleforth (AMPL), on its Initial Exchange Offering (IEO) platform, Tokinex. The sale is scheduled to start on June 13 and end when it reaches hard cap of $4.9 zillion.
idax, however, is not the first one to get into this new foray in cryptocurrency. OKEx, Binance and Bittrex are already in the IEO business.
Those who may be rather puzzling IEO with Initial Coin Offering (ICO) must are aware these two are diverse kinds of. According to experts, IEO has become increasingly popular because features many more advantages than its counterpart.
What is an Initial Exchange Offering?
First of all, IEO is a form of ICO; some call it a better version than it. Unlike ICO which you are not a crypto-wallet can avail, IEOs are exchange-specific. This means you need to surely be a user of the exchange that is offering it and buy the token using your account a exchange.
It'd be difficult to declare a winner in fight between an ICO as well as a IEO. Some prefer ICOs because is actually very open to public. On paper, likewise includes more chances of raising means. However, investors have started being skeptic about ICOs; you reasons for that.
Anyone who are going to convince investors with their white paper can raise money through ICOs. Frequently than not, the technology involved the actual planet business is unknown. Also, no 3rd party monitors ICOs. Scammers use this opportunity in accessible products . to collect funds instead deliver is actually promised.
Bitcoin extends losses, down more than 20% to below $6,300
Rise of smaller rivals throws up fresh challenge to bitcoin
What works best IEOs continually that the exchange which launches it monitors the process as the website owner. If the trusts the exchange, may be assured of the security of its IEO. Each means the reputation from the exchange is at stake. Could possibly help the IEO goes down, it may be to consider the exchange down south this particular.
IEOs As well as cons Cons
The sense of risk significantly lower in IEOs, and that may be reason enough to have more investors. Reputed exchanges get their own research and verification process to make sure that the token is legit. Users should be a little more confident while buying IEO tokens as these do never to trust a half-known startup but to believe in the exchange that is a lot more well-known.
Nevertheless, as with other investment option, IEOs too their very own limitations and risks. Greatest gripe we have question is that you should trust an exchange. Even though there a wide range of cryptocurrency exchanges around, couple of of them can be trusted. Methods them in accused of poor security and organizational.
Also, various blockchain experts are against IEOs for it is against the core value of this technology: decentralisation. When an exchange oversees the process, it simply controls the revenue flow while blockchain and cryptocurrency are fundamentally against a seasoned of third-party control.
In a collaboration with IDAX, kuverit will be holding an IEO to advance their new cryptocurrency exchange. The exchange will support cryptocurrencies, fiat, and various other securities. Boasting a large list of partnerships, kuverit hopes it would likely emerge as an industry owner.
However, individuals skills caught our eye about kuverit was that it seeks to host STOs. Securities are traded on kuverit through its own STO marketplace scheduled for you to become unveiled inside of the fourth quarter of 2019. Inherently decentralized, most of the traded tokens will be on Ethereum, including ERC-20 and ERC-721 tokens.
kuverit will have some fierce competition from existing security token platforms, however, like Tokeny and tZero.
The Standard Tokenization Protocol, or STP, is a decentralized network that allows any asset to be tokenized. But a positive aspect token platforms, compliance, validation and KYC/AML functions are produced directly into the blockchainallowing issuers to guarantee that everyone holding their token is following the rules of their jurisdiction.
announced that the protocol could unlock trillions of dollars in value, by making it easier to trade and issue tokens.
The cost-prohibitive nature of traditional funding methods has led to a rapidly increasing demand for solutions that simplify asset offerings, said Chen, in a comment. STP is in a unique position conserve billions of dollars businesses and startups that are unable to attain funding due to the costs involved with hiring security lawyers, accountants, and investment banks.
In addition, Chen suggested, the project would also help reduce crypto economy as a whole, by reducing illiquidity premiums and making it easier to safely move value.
Initially, Block72 <digital>asset investment bank] set to support the crypto ecosystem by helping blockchain projects around the world, he told Crypto Briefing. <B>ut projects are simply just half the equation. Associated with launch of STP required anymore . have worn-out to match the needs of crypto users all in the world, also as projects.
The sale will commence at 10 AM EDT on Tuesday, June 11th, continuing for 24 hours or until all tokens have been sold. Like some other recent IEO's, the cap has been set relatively low whenever compared with the excesses of the ICO model: STP hopes to raise $750,000 from the sale, with individual contributions capped at approximately $2,500. 75 million tokens are allocated for the sale, along with a maximum supply of 2 billion STPT.
Bittrex International has already launched several token sales, with mixed success. Site directories . IEO, RAID, was cancelled after the termination of one key partnership, as Crypto Briefing suggested. Another, Ocean Protocol, was considered a flop by some investors after the token price collapsed are actually has since recovered far.
But does not seem to bother the STP party. We're very excited to work with them, Chen told Crypto Briefing.We decided check out with Bittrex International since their community, like ours, is global, as well as the platform allows users buy more tokens in comparison to other IEO operating systems.
The IEO follows two private sales for the STP project, which raised a total of $7 million from prominent VC's like Neo Global Capital, BlockVC and Alphabit. Next biggest round raised $2 million for STP.
STP is often a very promising project, said Wayne Zhu, partner at NGC. The Block72 team is an experienced in this space plus they have helped many great projects realize and amplify their aspects.

<a href=>ieo coin</a>
<a href=>ieo insurance</a>

<a href=>best ieo to invest in 2019</a>

RitaLix on Friday, June 14, 2019 at 20:42

Наша бабушка серьезно заболела, и на время больницы малышу потребовалась няня. Муж быстро нашел подходящую на каком-то сайте, женщина выглядела солидно, и мы заключили договор. В частном порядке, с ежедневной оплатой. Юлия Линченко (Чекарева) 16.06.1978гр, тел +380957168219, так ее звали, заботой о ребенке себя не утруждала вовсе. Малыш был голоден, она объясняла, что есть не хотел. Странно, так не бывает. А еще синяк на лице, якобы от падения, хотя в его комнате нет острых углов, муж позаботился. Короче, уволили ее, от греха подальше, рисковать нельзя!

Add a comment

Email: (optional, not displayed to public)