Permalink
Browse files

add storm dir for logs folder to use absolute path for logs folder

  • Loading branch information...
1 parent 2ba30d2 commit c6712a1e7265bb72a72ba0e983e60d195071596f @haitaoyao haitaoyao committed Jan 30, 2012
Showing with 3 additions and 3 deletions.
  1. +1 −1 bin/storm
  2. +2 −2 log4j/storm.log.properties
View
@@ -63,7 +63,7 @@ def print_remoteconfvalue(name):
def exec_storm_class(klass, jvmtype="-server", childopts="", extrajars=[], args=[]):
nativepath = confvalue("java.library.path", extrajars)
- command = "java " + jvmtype + " -Djava.library.path=" + nativepath + " " + childopts + " -cp " + get_classpath(extrajars) + " " + klass + " " + " ".join(args)
+ command = "java " + jvmtype + " -Dstorm.home=" + STORM_DIR + " -Djava.library.path=" + nativepath + " " + childopts + " -cp " + get_classpath(extrajars) + " " + klass + " " + " ".join(args)
print "Running: " + command
os.system(command)
@@ -2,8 +2,8 @@ log4j.rootLogger=INFO, A1
log4j.appender.A1 = org.apache.log4j.DailyRollingFileAppender
-log4j.appender.A1.File = logs/${logfile.name}
+log4j.appender.A1.File = ${storm.home}/logs/${logfile.name}
log4j.appender.A1.Append = true
log4j.appender.A1.DatePattern = '.'yyy-MM-dd
log4j.appender.A1.layout = org.apache.log4j.PatternLayout
-log4j.appender.A1.layout.ConversionPattern = %d{yyyy-MM-dd HH:mm:ss} %c{1} [%p] %m%n
+log4j.appender.A1.layout.ConversionPattern = %d{yyyy-MM-dd HH:mm:ss} %c{1} [%p] %m%n

0 comments on commit c6712a1

Please sign in to comment.