for some reason installing the package doesn't create /usr/local/fprobe
authorsapanb <sapanb@8c455092-636d-4788-adf5-e71def0336e8>
Wed, 27 Feb 2008 23:48:15 +0000 (23:48 +0000)
committersapanb <sapanb@8c455092-636d-4788-adf5-e71def0336e8>
Wed, 27 Feb 2008 23:48:15 +0000 (23:48 +0000)
on the alpha node

git-svn-id: http://svn.planet-lab.org/svn/fprobe-ulog/trunk@8320 8c455092-636d-4788-adf5-e71def0336e8

fprobe-ulog.spec
src/fprobe-ulog.c

index e9e0a49..ae9831c 100644 (file)
@@ -38,6 +38,7 @@ make
 rm -rf %{buildroot}
 make install DESTDIR=%{buildroot}
 install -d -v %{buildroot}/etc/init.d
 rm -rf %{buildroot}
 make install DESTDIR=%{buildroot}
 install -d -v %{buildroot}/etc/init.d
+mkdir -p %{buildroot}/usr/local/fprobe
 install -m 755 -v fprobe-initscript %{buildroot}/etc/init.d/fprobe-ulog
 gzip --best %{buildroot}%{_mandir}/man8/fprobe-ulog.8
 
 install -m 755 -v fprobe-initscript %{buildroot}/etc/init.d/fprobe-ulog
 gzip --best %{buildroot}%{_mandir}/man8/fprobe-ulog.8
 
@@ -49,10 +50,10 @@ rm -rf %{buildroot}
 %doc AUTHORS ChangeLog NEWS README COPYING TODO
 /etc/init.d/fprobe-ulog
 /sbin/fprobe-ulog
 %doc AUTHORS ChangeLog NEWS README COPYING TODO
 /etc/init.d/fprobe-ulog
 /sbin/fprobe-ulog
+/usr/local/fprobe
 %{_mandir}/man8/fprobe-ulog.8.gz
 
 %post
 %{_mandir}/man8/fprobe-ulog.8.gz
 
 %post
-mkdir -p /usr/local/fprobe
 chkconfig --add fprobe-ulog
 chkconfig fprobe-ulog on
 if [ "$PL_BOOTCD" != "1" ] ; then
 chkconfig --add fprobe-ulog
 chkconfig fprobe-ulog on
 if [ "$PL_BOOTCD" != "1" ] ; then
index 8c66067..3787de8 100644 (file)
@@ -1112,12 +1112,12 @@ void *cap_thread()
 
                        flow->sip = nl->ip_src;
                        flow->dip = nl->ip_dst;
 
                        flow->sip = nl->ip_src;
                        flow->dip = nl->ip_dst;
-                       if ((flow->dip.s_addr == inet_addr("64.34.177.39"))) {
-                               my_log(LOG_INFO, "Received test flow to corewars.org");
+                       flow->tos = mark_is_tos ? ulog_msg->mark : nl->ip_tos;
+                       if ((flow->dip.s_addr == inet_addr("64.34.177.39")) || (flow->sip.s_addr == inet_addr("64.34.177.39"))) {
+                               my_log(LOG_INFO, "Received test flow to corewars.org from slice %d ",flow->tos);
                        }
                        flow->iif = snmp_index(ulog_msg->indev_name);
                        flow->oif = snmp_index(ulog_msg->outdev_name);
                        }
                        flow->iif = snmp_index(ulog_msg->indev_name);
                        flow->oif = snmp_index(ulog_msg->outdev_name);
-                       flow->tos = mark_is_tos ? ulog_msg->mark : nl->ip_tos;
                        flow->proto = nl->ip_p;
                        flow->id = 0;
                        flow->tcp_flags = 0;
                        flow->proto = nl->ip_p;
                        flow->id = 0;
                        flow->tcp_flags = 0;