• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Cat /proc/kmsg > kmsg.txt.....

Im trying to figure out why my touchscreen is not working. I've been told by a dev that initial impression is somehow i wrote over devtree files...

I need to get a kmsg.txt file but i am having a ton of difficulty... ill try to give you a quick explanation of what i've tried:

No problem connecting to the device in adb shell, i have # su rights, enter in the command
[HIGH]cat /proc/kmsg > kmsg.txt[/HIGH]

"/system/bin/sh: cat: /proc/kmsg: Permission denied" or i get a kmsg.txt file in the tools dir. that says

"Sh: can't create kmsg.txt: read-only file system"

I've tried gaining write privileges in windows 7 thru the permissions profiles/attrib/take ownership

I've tried to use the mount commands in various forms i've found all over forum posts and guides..

I have no touch screen just a keyboard that lacks the > key and the symbol key does not bring up a menu. Im assuming this is related to my main problem. None the less i cannot use the command on the terminal emulator i've managed to open.

Is there another way? I swear searched google for hours looking at every different adb command line to open write privlages to the phone, to the pc. debug is on, its rooted.. *sigh* Ive been at it all day.. i use to know DOS by heart so adb and attrib commands seem simple but everything i try makes no difference..
 
You should be able to just open a command window where you want and run

adb pull /proc/kmsg > kmsg.txt

or try it without the txt and use something like notepad++ to open it.

we have different phones, but mine also has a /proc/last_kmsg which seems to be more of a log style thing you might be looking for. so maybe pull that too.

that should just pull a copy of the file off the phone and drop it on your computer(make sure your an admin or in a folder that is read/write)

if you need root permissions on the phone side, try chmod or chown, but i dont think you should.

what phone do you got?
 
I have not tried w. the pull command but it seems the not recognize my ownership and permissions when i try to pull it thru adb. Is it an actual file i could just actually take from the file sys ? Or (i assume) its a command that starts a process and logs the results....

Its a Droid 4. I'll try again w. extra pull line but for some reason it seems I don't have permission to write to the PC or phone side... Id settle for it creating the log on the sdcard and I can pull It over but cat /proc/kmsg only seems to work w.o the > output. And I don't think the copy paste of that is the same as the log output file.
 
Hi, welcome to the forums!

If you have root access on your device, I would recommend doing the following:

[HIGH]adb shell su -c "cat /proc/kmsg > /sdcard/kmsg.txt"
(Wait a few seconds, then hit Control-C to stop it)
adb pull /sdcard/kmsg.txt[/HIGH]
 
Thank you both for your help by the way.

[HIGH]adb shell su -c "cat /proc/kmsg > /sdcard/kmsg.txt" (Wait a few seconds, then hit Control-C to stop it) [/HIGH]

[HIGH]
# -c "cat /proc/kmsg > /sdcard/kmsg.txt
[/HIGH]

Runs for a couple seconds, i hit ctrl+c, drops to cmd prompt. No file created on sdcard. Same thing with doing it without the /sdcard/ prompt.

Its rooted, i can use root explorer/titanium/SS. It says "bla bla bla has been granted super user permission" when i use the "su" command to enter superuser in adb shell. Changes prompt to #.
 
Same response, ctrl + c = no file..

If i run it and copy past the results is that not the same?

Is this what im looking for? err.. will it tell me whats up w/ the touch screen drivers?


 

Attachments

So the file i posted would of been pretty much what the cat /proc/kmsg > would of output? It starts at partition mounted then tries to activate drivers correct? I could send this file to the Dev and he can see what my touchscreen is doing?

(i hate windows 7 btw.. garbage w/ permission rights)
 
Back
Top Bottom