jeudi déc. 23, 2010

GlassFish Tip: log asadmin commands

This blog has moved to alexismp.wordpress.com
Follow the link for the most up-to-date version of this blog entry.

I don't think I've seen this tip mentioned before in blogs or documentation and yet have had the request from different users and customers. If you want to log all the asadmin commands, simply set the AS_LOGFILE environment variable to the name of a file.

% export AS_LOGFILE=/tmp/asadmin.log
% asadmin ...
% cat /tmp/asadmin.log
12/23/2010 14:31:33 EXIT: 0 asadmin list-domains
12/23/2010 14:32:39 EXIT: 1 asadmin start-domain
12/23/2010 14:33:27 EXIT: 0 asadmin start-domain
12/23/2010 14:33:58 EXIT: 0 asadmin list-domains
12/23/2010 14:34:04 EXIT: 0 asadmin list-applications
12/23/2010 14:34:21 EXIT: 0 asadmin undeploy org.beginningee6.tutorial_demo11_war_1.0
12/23/2010 14:38:13 EXIT: 0 asadmin stop-domain
12/23/2010 14:38:46 EXIT: 1 asadmin start-domain
12/23/2010 14:41:00 EXIT: 0 asadmin --verbose start-domain domain1
12/23/2010 14:41:58 EXIT: 0 asadmin get servers.\*
12/23/2010 14:42:14 EXIT: 0 asadmin get servers.server.server.resource-ref.jdbc/__TimerPool.enabled
12/23/2010 14:44:37 EXIT: 0 asadmin deploy ../../HelloHK2bis.war

If you think this should be the default behavior, file an issue (with "3.2" as the "Fix Version"). I'll vote for it!
If you're trying to troubleshoot asadmin (or simply curious) you can set export AS_DEBUG=true to obtain a chatty output.

About

This blog has moved

Alexis Moussine-Pouchkine's Weblog

GlassFish - Stay Connected

Search

Archives
« avril 2014
lun.mar.mer.jeu.ven.sam.dim.
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
    
       
Today
Blogroll

No bookmarks in folder

News

No bookmarks in folder