Rob HudsonFri Feb 2 09:04:54 PST 2007
Is there a way to syntax check a .py file without actually running it? I know Perl has perl -c. I know PHP has php -l. What does Python have? Thanks, Rob
Rob HudsonFri Feb 2 09:04:54 PST 2007
Is there a way to syntax check a .py file without actually running it? I know Perl has perl -c. I know PHP has php -l. What does Python have? Thanks, Rob
horstThu Feb 1 21:34:10 PST 2007
I need to burn data to a CD from Knoppix(most recent Knoppix version avail. --or older version if needed for whatever reason) I realize, I never had to fiddled with CD/DVD burning from the command line ...Or maybe I just don't see what I should be looking for in the Knoppix/KDE dropdown... (silly) At any rate, which kind of CD Toaster/Roaster Apps am I overlooking in the GUI, or what are the cmd-line apps on Knoppix? (any useful cmd-line options to share upfront?) Thanks a bunch...............................Horst (Hey, how is/was the rebel clinix tonight ? --I spent too much time on my bike in 'fresh' air this week to get out one more time...)
AlanThu Feb 1 18:39:29 PST 2007
Mr O wrote: > http://www.eviltechmonkey.com/images/my_house.jpg > > http://maps.google.com/maps?f=q&hl=en&q=1599+Park+Ave,+Eugene,+OR+97404&ie=UTF8&lr=lang_en&om=1&z=17&ll=44.090244,-123.14366&spn=0.005371,0.012199&t=h&iwloc=addr > > That should do. I really don't know why I posted the image last > time. It skips my mind that I have way too much space from my > hosting provider. The address listed is for Valley Restaurant > Equipment or thereabouts and not my house. The top link gives > more detail on exactly where my house is. Again, it is the blue > house directly across the street from the little boarded up > building. > Ok, maybe I'm the only one who is going to get lost, but google shows Valley Restaraunt Equipment at 1000 Maxwell(not 1599 Park Ave), which makes much more sense with the image you posted. -ajb
Jason LaPierThu Feb 1 14:08:57 PST 2007
I was just visiting this issue today. There was a pretty good discussion on this list a couple months ago on the DST changes and testing your linux installs to see if you're patched. Like: ~/$ date --date=3/12/2007 Mon Mar 12 00:00:00 PDT 2007 The "PDT" indicating correct DST usage. Another I saw was: ~/$ zdump -v /etc/localtime | grep 2007 /etc/localtime Sun Mar 11 09:59:59 2007 UTC = Sun Mar 11 01:59:59 2007 PST isdst=0 gmtoff=-28800 /etc/localtime Sun Mar 11 10:00:00 2007 UTC = Sun Mar 11 03:00:00 2007 PDT isdst=1 gmtoff=-25200 /etc/localtime Sun Nov 4 08:59:59 2007 UTC = Sun Nov 4 01:59:59 2007 PDT isdst=1 gmtoff=-25200 /etc/localtime Sun Nov 4 09:00:00 2007 UTC = Sun Nov 4 01:00:00 2007 PST isdst=0 gmtoff=-28800 Where the dates shown are the "spring forward" and "fall back" dates (if you see Apr 1 instead of Mar 11, something's wrong). On one Debian server, running sarge/stable, I was fine. On another, running Debian testing - it was wrong. Turns out I needed to install the "tzdata" package for it to work in deb-testing. Weird - cuz I don't have this package on my stable box. For non-linux stuff, well, no surprise, MS is dragging it's feet. The WinXP patch is currently set to "optional" but will supposedly be made "critical" at some point. A few admins tried to install the Exchange 2003 patch on two servers here on campus, both found that after installing the patch they could no longer mount the information store and had to remove the patch. MS promises to have a fixed patch soon. (Windows Vista and Exchange 2007 are already fixed) Apple has patched OS X 10.4.x, but no plans to patch 10.3.9 or earlier. There is an unoffical fix out there - it's basically a shell script. Fun for me - I haven't upgraded my server to 10.4 yet (because it's just a file server and the upgrade is a couple hundred bucks) or a couple of the Powerbooks that some of my users are using (because the difference between Panther and Tiger is what, some widgets and a new search function?). The lesson? If you want proper patches, buy the latest software off the shelf. Microsoft doesn't have time to debug old code and get it to change a pair of dates somewhere without breaking something else, and Apple doesn't have time to create a patch for their OS version of anything more than 2 years old - even if someone else can do it in 100 lines of bash scripting. Or, well. You know. Use open source. - Jason L. > -----Original Message----- > From: euglug-bounces at euglug.org > [mailto:euglug-bounces at euglug.org] On Behalf Of > silverlining2007 at gmail.com > Sent: Thursday, February 01, 2007 12:34 PM > To: Eugene Unix and Gnu/Linux User Group > Subject: [Eug-lug] Day Light Saving Change for 2007 > > May want to take a look at this: > > http://isc.sans.org/diary.html?storyid=2142 > _______________________________________________ > EUGLUG mailing list > euglug at euglug.org > http://www.euglug.org/mailman/listinfo/euglug >
Ben BarrettWed Jan 31 14:56:22 PST 2007
from http://linuxboxadmin.com/articles/postgresql-for-mysql-users.php "PostgreSQL uses the vacuumdb utility program to reclaim space from deleted records and optimize indexes. Vacuum should be scheduled to run via cron at least once a week." Do you use that? You might also like this older thread: http://archives.postgresql.org/pgsql-docs/2002-04/msg00001.php To answer your question, from http://developer.postgresql.org/pgdocs/postgres/functions-admin.html The functions shown in Table 9-48<http://developer.postgresql.org/pgdocs/postgres/functions-admin.html#F= UNCTIONS-ADMIN-DBSIZE>calculate the actual disk space usage of database objects. *Table 9-48. Database Object Size Functions* NameReturn TypeDescriptionpg_column_size(any)intNumber of bytes used to store a particular value (possibly compressed) pg_database_size(oid) bigint= Disk space used by the database with the specified OID pg_database_size(name) bigintDisk space used by the database with the specified name pg_relation_size(oid) bigintDisk space used by the table or index with the specified OID pg_relation_size(text) bigint Disk space used by the table or index with the specified name. The table name can be qualified with a schema name pg_size_pretty(bigint) textConverts a size in bytes into a human-readable format with size units pg_tablespace_size(oid) bigintDisk space used by the tablespace with the specified OID pg_tablespace_size(name) bigintDisk space used by the tablespace with the specified name pg_total_relation_size(oid) bigint Total disk space used by the table with the specified OID, including indexes and toasted data pg_total_relation_size (text) bigint Total disk space used by the table with the specified name, including indexes and toasted data. The table name can be qualified with a schema name pg_column_size shows the space used to store any individual data value. pg_database_size and pg_tablespace_size accept the OID or name of a database or tablespace, and return the total disk space used therein. pg_relation_size accepts the OID or name of a table, index or toast table, and returns the size in bytes. pg_size_pretty can be used to format the result of one of the other functions in a human-readable way, using kB, MB, GB or TB as appropriate. pg_total_relation_size accepts the OID or name of a table or toast table, and returns the size in bytes of the data and all associated indexes and toast tables. What do I win? :) ben On 1/31/07, Rob Hudson <rob at euglug.net> wrote: > > Is there a way, from within Postgresql, to view the filesize usage of > its databases and tables? That might be the best approach and sounds > easier than looking at the raw data directory. > > On Wed Jan 31, 2007 at 02:35:16PM -0800, larry price wrote: > > short answer: you can but it's ugly > > > > longer answer: > > start looking at the pg_catalog.* relations (use \d from psql prompt) > > as I understand it the files under $PG_DATA/base/ are named after > > oid's for tables and relations, but there are a lot of subtleties, and > > the whole point of a DBMS is to manage that bookkeeping for you. > _______________________________________________ > EUGLUG mailing list > euglug at euglug.org > http://www.euglug.org/mailman/listinfo/euglug > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://euglug.org/pipermail/euglug/attachments/20070131/3b25c930/attac= hment.htm
Rob HudsonWed Jan 31 14:49:29 PST 2007
Is there a way, from within Postgresql, to view the filesize usage of its databases and tables? That might be the best approach and sounds easier than looking at the raw data directory. On Wed Jan 31, 2007 at 02:35:16PM -0800, larry price wrote: > short answer: you can but it's ugly > > longer answer: > start looking at the pg_catalog.* relations (use \d from psql prompt) > as I understand it the files under $PG_DATA/base/ are named after > oid's for tables and relations, but there are a lot of subtleties, and > the whole point of a DBMS is to manage that bookkeeping for you.
Mark TurnerWed Jan 31 14:42:43 PST 2007
On 1/31/07, Matthew Jarvis <mattj at bikefriday.com> wrote: > Thanks Mark... > > I made some changes to see what compress will do for me, plus trimmed > down the # of logs from 4 to 2 - I'll see what happens... > > Do I have to do anything else to tell it to use this updated conf file, > or will it see the changes already? Well, you need to force logrotate to run more often the the default daily you see in most *nix's. I have a cron entry that runs logrotate -f to force logrotate to run hourly. -Mark
Ben BarrettWed Jan 31 14:16:52 PST 2007
strings? (can you run strings on it?) I'm sure there is a better solution, but strings is easy :) (strings myfile | less) Staying in the hackish realm, you can use lsof to see what files are open; I would guess the DB engine keeps a handle on all its files though... so that may not help differentiate between active tables. ben PS - Google was able to tell me that the number inside /var/lib/pgsql/data/base/ is the OID (Object Identifier) of the that DB. I'm not familiar enough with Postgres to know where to correlate that... sorry :) Knowing that, and that pgsql is threaded, you could do the lsof method I suggested above, and launch a bunch of queries to a specific DB/table to see what changes while the queries run (ie, do a... lsof|grep -c 16982 ... and when the number returned is higher, you're queryign that table... dirty hack). On 1/31/07, Matthew Jarvis <mattj at bikefriday.com> wrote: > > Rob Hudson wrote: > > I think Matt's asking if you can determine which files related to which > > tables... > > > > Ya, what _he_ said... <g> > > Matthew S. Jarvis > IT Manager > Bike Friday - "Performance that Packs." > www.bikefriday.com > 541/687-0487 x140 > mattj at bikefriday.com > _______________________________________________ > EUGLUG mailing list > euglug at euglug.org > http://www.euglug.org/mailman/listinfo/euglug > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://euglug.org/pipermail/euglug/attachments/20070131/7e71548e/attac= hment-0001.htm
Ben BarrettWed Jan 31 14:04:39 PST 2007
I think logrotate is spawned from cron; if so it should re-read the config when it runs next. Check your crontab --in general, if you edit a conf for a service that is in /etc/init.d/... then you need to restart that service. ben On 1/31/07, Matthew Jarvis <mattj at bikefriday.com> wrote: > > Thanks Mark... > > I made some changes to see what compress will do for me, plus trimmed > down the # of logs from 4 to 2 - I'll see what happens... > > Do I have to do anything else to tell it to use this updated conf file, > or will it see the changes already? > > Thanks again... > > Matthew S. Jarvis > IT Manager > Bike Friday - "Performance that Packs." > www.bikefriday.com > 541/687-0487 x140 > mattj at bikefriday.com > > > Mark Turner wrote: > > Its fairly easy to limit log file size if you use logrotate. In the > > configuration specification for each log you can give it a size > > parameter, which will rotate the log when it hits that size. > > > > Example: > > # sample logrotate configuration file > > > > /var/log/messages { > > rotate 5 > > weekly > > size=3D100k > > postrotate > > /sbin/killall -HUP syslogd > > endscript > > } > > > > > > On 1/31/07, Matthew Jarvis <mattj at bikefriday.com> wrote: > > > >> Is there a way to globally set how big log files can get? > >> > >> i.e. maillog, maillog.1, maillog.2 > >> > >> I was hoping that this global setting would also control apache, > >> postgres etc but that's prolly asking too much... > >> > >> > >> -- > >> Matthew S. Jarvis > >> IT Manager > >> Bike Friday - "Performance that Packs." > >> www.bikefriday.com > >> 541/687-0487 x140 > >> mattj at bikefriday.com > >> _______________________________________________ > >> EUGLUG mailing list > >> euglug at euglug.org > >> http://www.euglug.org/mailman/listinfo/euglug > >> > _______________________________________________ > EUGLUG mailing list > euglug at euglug.org > http://www.euglug.org/mailman/listinfo/euglug > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://euglug.org/pipermail/euglug/attachments/20070131/01b74f1f/attac= hment.htm
Rob HudsonWed Jan 31 13:37:15 PST 2007
I think Matt's asking if you can determine which files related to which tables... On Wed Jan 31, 2007 at 01:21:51PM -0800, larry price wrote: > those are the files that store the tables > > On 1/31/07, Matthew Jarvis <mattj at bikefriday.com> wrote: > >On my web server I have a bunch of files named something along the lines > >of this: > > > >/var/lib/pgsql/data/base/16982/492470 > > > >They are eating up my backup allowance on my hosted service and I'm > >curious which DB's and/or tables they are. > > > > > >-- > >Matthew S. Jarvis > >IT Manager > >Bike Friday - "Performance that Packs." > >www.bikefriday.com > >541/687-0487 x140 > >mattj at bikefriday.com > >_______________________________________________ > >EUGLUG mailing list > >euglug at euglug.org > >http://www.euglug.org/mailman/listinfo/euglug > > > _______________________________________________ > EUGLUG mailing list > euglug at euglug.org > http://www.euglug.org/mailman/listinfo/euglug >