# # strings
APLawrence.com -  Resources for Unix and Linux Systems, Bloggers and the self-employed

2003/12/15 strings command

I've removed advertising from most of this site and will eventually clean up the few pages where it remains.

While not terribly expensive to maintain, this does cost me something. If I don't get enough donations to cover that expense, I will be shutting the site down in early 2020.

If you found something useful today, please consider a small donation.



Some material is very old and may be incorrect today

© December 2003 Tony Lawrence

Extract printable strings from a file. The usual use is to look inside some data or program file to get possibly useful information out of it. It's also useful if you have a file that MIGHT contain garbage control characters and you just want to be safe.

Without any flags, strings doesn't necessarily search the entire file:


apl$ strings  -15 `which strings` | wc -l
     207
apl$ strings -a -15 `which strings` | wc -l
     208
apl$ strings - -15 `which strings` | wc -l
     242
 

But on a Linux box:

bash-2.05a$ strings  -15 `which strings` | wc -l
     47
bash-2.05a$ strings  -a -15 `which strings` | wc -l
     47
bash-2.05a$ strings  - -15 `which strings` | wc -l
     47
 

And on a BSD box, "-" and "-a" are equivalent:

bash-2.05a$ strings  -15 `which strings` | wc -l
     117
bash-2.05a$ strings  -a -15 `which strings` | wc -l
     172
bash-2.05a$ strings  - -15 `which strings` | wc -l
     172
 

If you found something useful today, please consider a small donation.



Got something to add? Send me email.





(OLDER)    <- More Stuff -> (NEWER)    (NEWEST)   

Printer Friendly Version

->
-> strings


Inexpensive and informative Apple related e-books:

Photos: A Take Control Crash Course

iOS 10: A Take Control Crash Course

Take Control of iCloud

Take Control of Apple Mail, Third Edition

Take Control of iCloud, Fifth Edition





More Articles by © Tony Lawrence





Printer Friendly Version

Have you tried Searching this site?

This is a Unix/Linux resource website. It contains technical articles about Unix, Linux and general computing related subjects, opinion, news, help files, how-to's, tutorials and more.

Contact us


Printer Friendly Version





The best of us would rather be popular than right. (Mark Twain)




Linux posts

Troubleshooting posts


This post tagged:

Scripting

Shell

UnixWords



Unix/Linux Consultants

Skills Tests

Unix/Linux Book Reviews

My Unix/Linux Troubleshooting Book

This site runs on Linode