You can configure the following property in $HIVE_HOME/conf/hive-log4j.properties:
hive.log.dir=<your location> The default value of this property is ${java.io.tmpdir}/${user.name}. Thanks, Satish On Thu, Jul 17, 2014 at 11:58 PM, Yang <teddyyyy...@gmail.com> wrote: > we just moved to hadoop2.0 (HDP2.1 distro). it turns out that the new hive > version generates a lot of logs into /tmp/ and is quickly creating the > danger of running out of our /tmp/ space. > > > I see these 2 different logs : > > [myuser@mybox ~]$ ls -lt /tmp/myuser/ > total 1988 > -rw-rw-r-- 1 myuser myuser 191687 2014-07-17 11:17 hive.log > -rw-rw-r-- 1 myuser myuser 14472 2014-07-16 14:43 > myuser_20140716143232_d76043ed-1c4b-42a0-bf0a-2816377a6a2a.log > -rw-rw-r-- 1 myuser myuser 14260 2014-07-16 14:04 > myuser_20140716135353_de698da0-807f-4e3b-8b97-5af5064b55f2.log > -rw-rw-r-- 1 myuser myuser 14254 2014-07-16 13:42 > myuser_20140716133838_208329bd-77bb-4981-a2e9-e747647d0704.log > > > > from the doc at > https://cwiki.apache.org/confluence/display/Hive/GettingStarted#GettingStarted-ErrorLogs > I can see that "per Hive session basis in /tmp/<user.name>/, but can be > configured in hive-site.xml > <https://cwiki.apache.org/confluence/display/Hive/AdminManual+Configuration> > with > the hive.querylog.location property.", > but I tried to pass it to -hiveconf > hive.querylog.location=/tmp/mycustomlogdir/ > , doesn't seem to work; the hive.log location is not changed by this > approach either. > > so how can I change the location of both the logs , by some per-script > params ? (i.e. we can't afford to change the system hive-site.xml or > /etc/hive/conf etc) > > Thanks a lot > Yang > -- _____________________________________________________________ The information contained in this communication is intended solely for the use of the individual or entity to whom it is addressed and others authorized to receive it. It may contain confidential or legally privileged information. If you are not the intended recipient you are hereby notified that any disclosure, copying, distribution or taking any action in reliance on the contents of this information is strictly prohibited and may be unlawful. If you have received this communication in error, please notify us immediately by responding to this email and then delete it from your system. The firm is neither liable for the proper and complete transmission of the information contained in this communication nor for any delay in its receipt.