'how can we see the .exe printf message [closed]
I have an question about the .exe log. I am using raspberry pi 4 module with Debian OS where I am running my c-program from the .service base auto-start .exe process. Which is running well So whenever raspberry Pi will restart my program will start automatic.That's fine but how do I see my print-f log from the terminal.
When I run exe with below line it will print the message but when this .exe running through the auto-services how can we check the log ?
Is there any linux command which will help to print run-time message. ?
root@raspberrypi: $./test.exe
Solution 1:[1]
it seems that you are using a systemd service unit, to run your binary.
if so, you can use:
journalctl -u <name>.service
(replace <name>
with the actual name of your service)
sidenote:
do not use the .exe
extension for your elf-binaries ("linux binaries").
.exe
is an extension for PE32 files ("windows executables"), but Linux is perfectly capable of running a file with an arbitrary name (extensions have no meaning under linux).
so: executables typically have no extension at all, and you should get used to that: use test
instead.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 |