STUPID CLAMD!!
Friday, July 31, 2009, 05:10 PM - Linux
I ran into an issue where clamd (the clam anti-virus daemon) was using 100% of my CPU time, forcing other programs (like auth!) to fail. After playing with several settings, I finally figured out how to disable clamd:
1. touch /var/qmail/supervise/clamd/down
2. vi /var/qmail/control/simcontrol
3. change :clam=yes to :clam=no
4. save the file and run /var/qmail/bin/simscanmk
5. qmailctl restart
6. qmailctl stat
You should get a message that clamd is down (since we added a file named "down" in the clamd folder for supervise) and it should stay down when we restart qmail.
[ add comment ] | [ 0 trackbacks ] | permalink |




( 3 / 635 )What kind of timestamp is THAT??!
Friday, July 31, 2009, 03:26 PM - Linux
If you're like me and run qmail with multilog to split things out into multiple, readable logs, you end up with some crazy looking log entries, like this one: @400000004a736ed035017b1c tcpserver: status: 26/400. The message is pretty readable, but the timestamp, @400000004a736ed035017b1c, not so much. However, there is a solution. Instead if just issuing a tail -f filename, pipe that output to tai64nlocal, like this: tail -f filename | tai64nlocal. This will convert the output to something much more readable, like this: 2009-07-31 15:25:58.861012500 tcpserver: status: 31/400.
Happy Logging!
[ add comment ] | [ 0 trackbacks ] | permalink |




( 3 / 490 )NHibernate 2.0 works on MONO!!
Tuesday, August 26, 2008, 07:13 PM - Linux, .NET, NHibernate
Ok, so I'm probably not the first person to figure this out, but I'm ecstatic! Now I can upgrade to NHibernate 2.0 and start playing with the Fluent interface without having to maintain 2 separate sets of code![ add comment ] | [ 0 trackbacks ] | permalink |




( 2.9 / 187 )NHibernate 1.2 to 2.0
Tuesday, August 26, 2008, 07:03 PM - Linux, .NET, NHibernate
I took the opportunity to update one of my projects to NHibernate 2.0 today, because I want to start mapping with Fluent instead of XML. I took an existing working project and replaced the 1.2 references with the 2.0 replacements. This worked fine, except that the NHibernate.Expression namespace is now gone, replaced by the NHibernate.Criterion.
Once I replaced these using statements, I started getting a "Hibernate.MappingException : Could not compile the mapping document: <hbm.xml file> ----> System.Collections.Generic.KeyNotFoundException : The given key was not present in the dictionary." error. It turns out, you have to call "config.Configure()" now, where this happened in 1.2 automatically.
Once I added this call to my Session Factories, the application reported that it could not find "hibernate.cfg.xml". I use mapping in my Web.Config instead of the XML file, so I figured this had changed. A couple of minutes with Google, and Viola! The Web.Config now looks like the xml configuration documents did in 1.2, which needs to look like this:
<configSections>
<section name="hibernate-configuration" type="NHibernate.Cfg.ConfigurationSectionHandler, NHibernate"/>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,log4net"/>
</configSections>
<hibernate-configuration xmlns="urn:nhibernate-configuration-2.2">
<session-factory>
<property name="connection.provider">NHibernate.Connection.DriverConnectionProvider</property>
<property name="dialect">NHibernate.Dialect.MySQLDialect</property>
<property name="connection.driver_class">NHibernate.Driver.MySqlDataDriver</property>
<property name="connection.connection_string_name">connection_name</property>
<property name="connection.isolation">ReadCommitted</property>
<property name="max_fetch_depth">0</property>
<property name="show_sql">true</property>
<property name="query.substitutions">true=1, false=0</property>
</session-factory>
</hibernate-configuration>
I did try replacing the name hibernate-configuration with another name (like "nhibernate" and it didn't work, so it looks like it needs to have that specific name).
I am now off to test it on Mono!
[ add comment ] | [ 0 trackbacks ] | permalink |




( 3 / 209 )Do you hate ZENworks?
Monday, March 31, 2008, 11:57 AM - Technology, Linux
I you run OpenSUSE like me, you probably run across the "Synchronize with ZENworks" checkbox every time you change your update sources, and occasionally you forget to uncheck it, and it takes FOREVER to synchronize, only to tell you that it failed.
If you hate this as much as I do, then try this:
rpm -e zmd libzypp-zmd-backend sqlite-zmd rug
Presto! zenworks tools are uninstalled, and the option is greyed out in YAST!!
[ add comment ] | [ 0 trackbacks ] | permalink |




( 3 / 199 )Next






