How can I view stdout/stderr of a startup application?

Adam Paetznick

Some of the commands that I have in Startup Applications do not start properly when I login. (In particular I am having trouble with gtk-redshift.) In order to debug, I would like to be able to view stdout/stderr. I haven't found a log file for Startup Applications. I have tried redirecting to a file using ">> log.txt" with no success.

How can I see stdout/stderr for a Startup Application? Better yet, is there a log file for Startup Applications?

user76204

I think the best thing to do would either put the bash command further below in startup or put it in a bash script and select that in your startup applications. I have added the -v option so the application records all its actions with the greatest of detail; some applications have other verbosity settings and even various levels that you can specify.

The &> redirection used is the same as 2>&1 in that it redirects all of the program's output (stderr, stdout) to the specified file, i.e. &>/home/mike/redshift.log.

Here is the command that could be used to set up logging, and it could be used for other programs, if modified appropriately.

bash -c "setsid /usr/bin/gtk-redshift -v -l 40.77:-73.9 -t 6500:5500 &>/home/mike/redshift.log"

These are just sample test settings, substitute these values for your own; you may want to put the command, modified appropriately in a bash wrapper for your startup entry as the above command-line is quite long.

An excerpt from the log created at /home/mike/redshift.log:

Gamma ramp size too small: 0
Failed to start adjustment method randr.
Trying next method...
Location: 40.770000, -73.900002
Brightness: 1.00
Gamma: 1.000, 1.000, 1.000
Using method `vidmode'.

The log continues and should give you the information you need. Some programs such as vlc do have options that you can set up so their logging can be sent to syslog, but I prefer that each program has its own separate log.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

How can I make Ubuntu to run only one application on startup

From Dev

How can I view the traffic of this application?

From Dev

In the startup scripts generated by gradle's application plugin, how can I have the program name passed in to the application?

From Dev

How can I view a sample flask application from github?

From Dev

How can I have multiple view on my android application?

From Dev

How can I make a similar application using street view?

From Dev

How do I delay a startup application in Lubuntu?

From Dev

How do I set uget as a startup application

From Dev

How Can I Run the WPF application at Windows startup without using any code

From Dev

How can I get a startup application to run in another workspace other than #1?

From Dev

How Can I Run the WPF application at Windows startup without using any code

From Dev

I can't find Global.asax, how to handle Application_Error in webform 4.5 in startup class?

From Dev

how can i write a shell script that will run at startup and introduce a delay in the start of an application

From Dev

How can I make Shutter open at startup?

From Dev

How can I reduce startup time for vim?

From Dev

How can I prevent Supervisor to run at startup?

From Dev

How can I add startup timings to MiniProfiler?

From Dev

How can I prevent Supervisor to run at startup?

From Dev

How can I run a program on startup, minimized?

From Dev

How can I make Shutter open at startup?

From Dev

How can I remove a duplicate startup entry?

From Dev

How can I execute commands on startup in awesome?

From Dev

How can I configure a service to run at startup

From Dev

How can I disable postfix on startup?

From Dev

How can I fill a dataset on app startup

From Dev

How can I enable the lighttpd on startup in Ubuntu

From Dev

How can I run a program on startup, minimized?

From Dev

Can I get the iOS Startup Notification after the application has started?

From Dev

How do I execute an asynchronous startup on a WPF application?

Related Related

  1. 1

    How can I make Ubuntu to run only one application on startup

  2. 2

    How can I view the traffic of this application?

  3. 3

    In the startup scripts generated by gradle's application plugin, how can I have the program name passed in to the application?

  4. 4

    How can I view a sample flask application from github?

  5. 5

    How can I have multiple view on my android application?

  6. 6

    How can I make a similar application using street view?

  7. 7

    How do I delay a startup application in Lubuntu?

  8. 8

    How do I set uget as a startup application

  9. 9

    How Can I Run the WPF application at Windows startup without using any code

  10. 10

    How can I get a startup application to run in another workspace other than #1?

  11. 11

    How Can I Run the WPF application at Windows startup without using any code

  12. 12

    I can't find Global.asax, how to handle Application_Error in webform 4.5 in startup class?

  13. 13

    how can i write a shell script that will run at startup and introduce a delay in the start of an application

  14. 14

    How can I make Shutter open at startup?

  15. 15

    How can I reduce startup time for vim?

  16. 16

    How can I prevent Supervisor to run at startup?

  17. 17

    How can I add startup timings to MiniProfiler?

  18. 18

    How can I prevent Supervisor to run at startup?

  19. 19

    How can I run a program on startup, minimized?

  20. 20

    How can I make Shutter open at startup?

  21. 21

    How can I remove a duplicate startup entry?

  22. 22

    How can I execute commands on startup in awesome?

  23. 23

    How can I configure a service to run at startup

  24. 24

    How can I disable postfix on startup?

  25. 25

    How can I fill a dataset on app startup

  26. 26

    How can I enable the lighttpd on startup in Ubuntu

  27. 27

    How can I run a program on startup, minimized?

  28. 28

    Can I get the iOS Startup Notification after the application has started?

  29. 29

    How do I execute an asynchronous startup on a WPF application?

HotTag

Archive