7

To give Bond eth0 and LTE Modem a pointer, I was trying to find a previous answer I knew I'd written about how we use multiple ISPs at work. I was also going to point to some other folk's answers, but first of course I had to find them. Policy routing on Linux is done with the ip command's rule subcommand. So the answers should all include ip rule, but searching for that didn't really find any. I know I have written one, so I searched:

"ip rule" is:a user:977
    → 0 results.

Errr, I managed to find my answer eventually: Routing for multiple uplinks/providers and note the line Maginot:~# ip rule ls — "ip rule" is right there!

If I search for just "rule" instead, it finds it.

All I can figure is that search is ignoring code blocks. Ugh. Presuming that's the case, is there some trick (other than the obvious, why did you bother with a search other than Google?) to get search to search inside code blocks?

7

It does seem like search just ignores code blocks; I can't find any mention of if this is intentional, it seems like an odd decision, and the meta thread about the new search engine implies that it should work:


There is a way to search only code blocks, the entirely undocumented code: filter, so code:"ip rule" is:a user:997 will work. Note that that wouldn't find answers where you mentioned "ip rule" outside a code block; I think you'd have to run two separate searches to cover both cases.

  • 1
    Well, this explains why I found nothing relevant while searching for rm "cannot remove" "is a directory", but after I posted this question it turned out to be a duplicate of this one. My original search should have found the other question and prevent me from posting a duplicate. – Kamil Maciorowski Apr 11 '18 at 5:47

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .