Posts Tagged ‘learning’
bicycle, ecology, event, learning, local, travel
In events, learning, various on June 11, 2010 at 4:15 pm
I’m going to need a weekend at home by the time I’m done with my whirlwind of meetings (note: Las Vegas is surreal and fascinating.) but this sounds great. A weekend of biking and bicycle repair workshops in the Catskills with my friend Chris:
As you might have heard, my friend Ryan and I are putting on a weekend long bicycle workshop in upstate NY on the weekend of June 25-27th. This is the first time we have put on this workshop and have been unable to register any participants as of yet. However, our shortfall is your gain. We would like to do this workshop in the future and we feel your participation and feedback will be great help for the workshop’s future development. Thus, we are sending you a personal invite to join us for the weekend for a greatly reduced $100 per person! This price includes: five great meals, lodging, rides, and workshops. This is all in the context of Woodbourne, NY at a house that is on 15 acres of land. You will be responsible for getting yourself and your bicycle to the location. Read the rest of this entry »
art, artists, copyright, event, learning, software freedom
In events, learning on June 8, 2010 at 1:31 pm
I won’t be around on June 10, but this will be interesting. Promise:
Please join Not An Alternative, Eyebeam Art and Technology Center, and Upgrade NY! this Thursday, June 10 for the opening of Re:Group: Beyond Models of Consensus, an exhibition which examines models of participation and participation as a model in art and activism.
Read the rest of this entry »
command-line, instructions, irc, learning, linux, software, software freedom, technology, ubuntu
In learning, linux on May 26, 2010 at 3:28 pm
Next task: make a bootable USB thumb/stick/drive/thing to rescue a busted machine (In this case, little old Brahms). dkg, as ever, knows what’s what and gave me great advice:
Bootable USB sticks are just like bootable hard drives for modern computers. Partition them with parted, use mkfs to create a filesystem on them, use grub-install to give them a bootloader, put a kernel and an initial ramfs on them, configure the bootloader to load them, and away you go.
He even offered me his filesystem rescue debirf image with the latest 686 kernel from debian unstable. Read the rest of this entry »
command-line, learning, linux, software freedom, technology, ubuntu, whining
In linux on December 13, 2009 at 6:34 pm
Okay, lazyweb:
Why can’t I play DVDs and why, when I have installed in my computer two RAM modules of 2GiB each, does my computer have 2.9 GiB of the RAMS? Why?
On the DVD end, I have installed one million things and gotten from an error in Totem (“no uri handler implemented for dvd”) to Totem quietly crashing when I try to play a DVD. VLC spins the disk and then stops. /var/log/messages shows this after trying to run VLC:
Dec 13 13:10:02 luna kernel: [10853.901791] sr 1:0:0:0: [sr0] Add. Sense: Media region code is mismatched to logical unit region
Dec 13 13:10:02 luna kernel: [10853.906376] sr 1:0:0:0: [sr0] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Dec 13 13:10:02 luna kernel: [10853.906386] sr 1:0:0:0: [sr0] Sense Key : Illegal Request [current]
Dec 13 13:10:02 luna kernel: [10853.906397] Info fld=0x98d0
Dec 13 13:10:02 luna kernel: [10853.906402] sr 1:0:0:0: [sr0] Add. Sense: Media region code is mismatched to logical unit region
Read the rest of this entry »
learning, organic internet, software, teaching, technology
In learning, various on October 6, 2009 at 9:17 pm
Via dkg, whose excellent essay Technical Architecture Shapes Social Structure you all already read when we first published The Organic Internet, comes an academic variation on that theme: Insidious pedagogy: How course management systems affect teaching. Normally I’d bookmark and move on, but this is extra interesting (and I haven’t even read it yet.)
learning, letters_home, politics, software freedom, storytelling, technology, truth_in_advertising
In learning, misc, various on September 10, 2009 at 5:12 pm
I haven’t been following the Google Books lawsuit and settlement proposal too closely because I don’t often think of myself as a book author. Not in the sense that Google Books or the settlement will impact my livelihood. It hadn’t actually occurred to me that the settlement might impact my freedom. But a press release from the Software Freedom Law Center caught my eye:
Today SFLC filed a letter with the United States District Court for the Southern District of New York objecting to the Google Book Search Copyright Class Action Settlement. In the letter, filed on behalf of the FSF and author Karl Fogel, SFLC asks the court to consider the impact of the settlement upon members of the class who have distributed their works under Free licenses.
I’m embarrassed to confess I had been thinking that this lawsuit (You are of course familiar with the lawsuit. Right?) was more academic than all that. I was thinking about what it means that Yahoo, Amazon and Google get to go sit in a darkened room somewhere (an expansive board room with a fine catered lunch, more likely) and rewrite copyright law all by themselves. I wasn’t thinking about freedom.
Read the rest of this entry »
learning
In various on February 27, 2009 at 12:27 am
- My reBlog project is still lagging so I can’t seamlessly repost, say, idealab posts.
- Canonical link tags? Swoon. Could everyone please adopt this week? Kthxbye.
- Poll question: should I start another blog? I sort of want a really open kitchen door for Gotham Gazette. Or I can just try to figure things out here. One or the other.
- Seriously though, I’m trying to figure out why our newsletters are triggering spam filters.
X-Spam-Status: Yes, score=5.692 tag=-999 tag2=999 kill=4 tests=[HTML_50_60=0.13, HTML_MESSAGE=0.001, MIME_HTML_ONLY=0.414, MSGID_LONG=0.899, MSGID_MULTIPLE_AT=2.88, SARE_UNI=0.591, SARE_UNSUB38=0.777]
X-Spam-Status: Yes, score=5.692 tag=-999 tag2=999 kill=4 tests=[HTML_50_60=0.13, HTML_MESSAGE=0.001, MIME_HTML_ONLY=0.414, MSGID_LONG=0.899, MSGID_MULTIPLE_AT=2.88, SARE_UNI=0.591, SARE_UNSUB38=0.777]
It seems like the big killer is MSGID_MULTIPLE_AT.
So maybe I’ll just go look into that now.
command-line, learning, linux, technology
In various on December 2, 2008 at 9:12 pm
Worth trying: sar -q for a rundown of queue lengths and load averages. Also pstree and I need to sort out what this:
I reniced the gzip process with a low priority level to reduce the load it’s putting on your server. I’d recommend running these scripts with a +19 niceness during periods low traffic to reduce the impact they’re having on your server.
means.
learning, scheming, software freedom, teaching, technology
In various on November 30, 2008 at 8:10 pm
When the free lunch comes with a seminar on affiliate marketing opportunities and other ways to make a buck with pyramid schemes, it is a very special kind of free, nothing like kittens or beer or flying birds or freedom. Google is that kind of free, whether you believe that or not. And, I’m falling for Google Calendar. I’ve fallen. Fallen so hard that I’m documenting it for you.Because one thing it does nicely is import events from a CSV file. The catch is that if your CSV file is set up wrong, you just get an error that says “Sorry, Calendar is unavailable right now” when that isn’t the problem at all. So, if you tried to be sneaky and note the required fields with an asterisk or a wee “(required)” you’ll just be told to come back later. You won’t be told that Google can’t read your document.
Anyway. This Works.
Here’s the thing: today, Google is hanging on strong. But we’ve been over this with Flickr and del.icio.us. You may recall that both were acquired by Yahoo in the last year or two. And you may recall that Yahoo was about to be bought by Microsoft back in May, a buying that didn’t happen when Yahoo stock was at $37/share. Last I checked it was hovering around $9/share (actually, it is back up to 11). My sources (okay, the guy on the bus) say that the campus and soda machines are worth about $8/share which means that somewhere around $8 it starts to be worth it to takeover the whole thing and start selling off the chairs at a yard sale. Which means that I have no idea who is going to “own” Flickr or del.icio.us in six months. Not me, I know that, because neither is free.
So I’m trying to migrate. It helps that Yahoo’s system means that I am never entirely sure how to log in to my Flickr account anymore. I don’t take notes when I do login. I can never remember my username (actually, I have two). So I installed Gallery and if I ever figure out how to it to talk to Ubuntu in the webdav tongue, I might actually use it. And I’m trying to figure out a good substitute for del.icio.us, which is now just “delicious” anyway, which is lame.
learning, scheming, teaching, technology
In various on November 30, 2008 at 7:41 pm
free association, that was. I’m not even going to explain. I tried, this morning, to go off on a decadent adventure in the freezing rain but it didn’t work out as I had planned. Choice Greene turns out not to have seats, the expanded Pioneer still doesn’t sell cranberries and there was a line out the door at Choice. So my own living room it is. We did finally turn on the heat.
Oliver wrote, though. mailx v. mutt
I’ve been playing around with some shell scripting on my laptop and reading about command line email clients. The book I have talks about mail and mutt but only talks about how to read and send email with them,
mutt seems pretty good for sending but with out the program on my laptop I don’t know if it will retrieve them too. Do you know of any such programs that can download the messages from a pop or imap server? When we get to Guam in a week I’ll try downloading those two programs and looking at the help and man files but since time in port is so limited I figured I should make sure I’m getting the packages I need now since I’ll next have web access around the 22nd of December.
I envy his high seas. My people are mutt people when they aren’t using Eudora. I haven’t used Mutt since I worked at bway.net, and I found it frustrating because it wasn’t Pine and Pine was better because I knew how to use it. Funny how that works.
Mutt, though, ought to be a functional IMAP client. This is a good rundown of how to connect, but I think you are saying you want to store your IMAP messages offline. Store a copy.
Marius Gedminas, a generally helpful person and the author of a handful of generally useful tools, wrote a good response to some questions about fetchmail and mutt and IMAP that actually spells out some common points of confusion really well. So that might be helpful, just in terms of putting things in context. Another good read is Dave who eventually gives up, but first stews up a combination of mutt, UW IMAP, Isync and mairix.
I should dig in a little deeper. I’ll let you know how it goes.
databases, learning, lebanon, software freedom, teaching, technology
In various on September 16, 2008 at 10:24 pm
A casual acquaintance (his father married us, which is not especially casual, I guess) traveled a semi-public breakup on Facebook. First his relationship status changed (“is no longer engaged”; “is single”) and then his status went through a bit of a wringer (“I thought she loved me back _UCK!!!!”;” _UCK! _UCK!_UCK!”*). I pointed this out to N. who called it weird. It is. It is also nice to know that if you choose to “befriend” me on facebook, you’ll have to decide whether to pretend you didn’t notice that I went through a wringer or to say something kind about it. I suppose you have other options, but I’m lucky to be old enough that most people seem to sit on that particular fence and not the one down the road between “say something snotty” and “take advantage of the situation”. What is also nice is that when the Rabbi’s son finally did send round a note about how he’s looking for a place (less than a grand a month, share okay, he has a dog and a bike or two and he’s a genuinely nice guy; anyone?) he didn’t have to explain. Sometimes not having to explain is worth a lot.
We’ve all been through wringers, and when someone you love is attached to a lot of tubes it is really really nice to know that everyone knows. That little bit of “okay, I don’t have to explain.” smooths some rough edges in the rest.
My point is, that Calc’s date functions are sorely lacking (hah! you thought I was going to talk about life, didn’t you?) as far as I can see. Read the rest of this entry »
learning, sustainability, technology, truth_in_advertising, ubuntu
In various on September 16, 2008 at 12:33 pm
The thing is, this is my fault. Or halfway. I didn’t say “well, if you want to run Windows I don’t know what kind of machine you should buy but I know you need to buy it with it’s proprietary operating system pre-installed.” What I said was “eBay is rotten with open-box resellers. Get a ThinkPad.” When he said “I have Windows XP I can install.” I didn’t say “That isn’t how it works, honey. It won’t work and you won’t be able to get support and I don’t really know the first thing about troubleshooting Windows anymore and I don’t really have anyone I can ask because the people who I know who are willing to go out of their way to help me figure out my Ubuntu installation are doing it because:
- They like me. People like N., too. So someone ought to be able to help him get his laptop running?
- They believe in software freedom. And they know that helping me iron out the creases in my own machine will make it that much easier for other people to run Free Software. Because together we report bugs and sometimes even propose fixes to them, we offer to help other people over their own hurdles. And because here, in the notebook, I write such brilliant and useful advice about how to use your Free Software better yourself. And that is worth something to all of us because it makes our software better.
So who gains when I spend a day (two, going on. Gah.) figuring out where on earth to get the device drivers that a Lenovo ThinkPad needs to run the version of XP Pro that came with a Dell tower. Most notably, he’s missing functional networking drivers. Which makes it really hard to get online and figure out what else is missing. N might gain (he’ll have a usable machine), and Microsoft will gain (I’m assuming that Consigliere is phoning home). And I’ll gain a little knowledge. Next time someone I know wants to install XP on a laptop that came with Vista, I’ll know what they need to do to get it working. Which makes it easier for people to use Windows. Which helps Microsoft.
The real question is this: of all the people who I ought to be able to persuade that Ubuntu is worth the extra work (extra work for him. Windows is just extra work for Moi since I’m the one doing it. And eventually I will have worked it out and that will be that. Or: maybe I won’t. You can’t run Windows Update without a good product key for XP. I’m not sure we have that.
What I’m kind of thinking of doing is saying, look here: I know you need this laptop. How about I partition it, put Hardy Heron on one partition, put your thieved XP that was only ever meant to be installed on the Dell desktop it came with.
PS, speaking of fools … I’m just wondering (I know I said the same last night) when we can get back to that conversation about privatizing social security. Because it sure seems like an excellent idea to me right now.
command-line, learning, sed, technology, whining
In various on September 4, 2008 at 6:12 pm
What if I had a shitton of ancient shtml files that all, somewhere near the top of the body, contained a line like “BEGIN MAIN CONTENT”?
What if I wanted to wipe everything above that and substitute some include script? I’d use sed, right? Read the rest of this entry »
databases, design, learning, linux, technology, ubuntu, whining
In various on August 26, 2008 at 7:05 pm
OpenOffice has a database app. It has come a long (long, long) way over the last few years but uff is it ever just not there yet. I do need the query browser. Things you can’t do with OOo Base include add a fulltext index. Not with the gui because the gui doesn’t know that much, and not with the query browser because it balks. CREATE FULLTEXT INDEX `FILER_NAME` ON `commcand` (`FILER_NAME`); gets me an error (“syntax error, unexpected $end, expecting BETWEEN or IN or SQL_TOKEN_LIK”) in Base’s interface (“Run Query”) but worked just fine at the mysql command line. Same for “SHOW INDEX FROM tablename“. Works fine at the command line, OOo balks.
So OOo Base isn’t just translating between the two.
I’ll probably update this post as I come up with more new and different things to complain about.
command-line, databases, learning, linux, software freedom, teaching
In various on August 22, 2008 at 10:53 pm
Observation: OpenOffice’s native database format is a pain. It is impossible to work with, impossible it import data into. A pain.
People keep telling me that OOo will talk to MySQL, but I haven’t ever bothered to sort it out. Lately, though, some guy at NYPIRG has been working magic with campaign finance data and I wanted a piece of the action. I turns out that the state Board of Elections does publish filing data regularly. Comma delimited no less. Or, rather, comma delimited data stored in a MS Windows only proprietary compression format.
I know I’m famous for saying that PHPmyAdmin makes you weak, but sometimes some weakness is called for. Especially when you’ve got a monstrosity of data and you want to be able to look around at it in a halfway useful way.
I’ve looked at the instructions before a few times over and never felt quite inspired to actually follow them, but with inspiration in hand I went for it this week. It took all week, but that had a lot more to do with trying to sort out a seamless way to modify the date formats for import into MySQL than with the OOo Base / MySQL connection.
To start with, I followed these instructions for installing Connector/ODBC. Or rather, I ran sudo aptitude install unixodbc libmyodbc unixodbc-bin and took it from there.
Most of the process you only need to do once. Then comes the fussy part. With Connector/ODBC in place, adding an existing MySQL database as a data source available to OOo Base requires you to:
run sudo ODBCConfig
look under the System DSN tab for the add button
select the MySQL ODBC Driver you configured the first time around and say OK
manually add the name of your database (it might not be in the pulldown)
Only then, can you use OOo Base’s New -> Database wizard to
connect to an existing MySQL database;
connect using ODBC;
and then select the database and supply a username and password for it.
It is a little crazy making to plod through the ODBC Config screens, but it does work.
learning, linux, software freedom, technology
In various on August 21, 2008 at 8:26 pm
Alyosha Dubinskaya, do you have any idea how much I love to get questions like this? I mean like this:
Amanda, what is google analytics?
i read this
http://www.google.com/analytics
and it doesn’t explain anything to me.
i just installed no-script for firefox today
and am shocked at how many places there is a script from google analytics!
Read the rest of this entry »
learning, local, myself, real estate
In various on July 30, 2008 at 2:48 pm
Tate says we have terrible luck with real estate. I suspect that we just want more than we can afford so we push the edges and wind up getting burned.
Either way, we had a contract, we had a mortgage. We had a lawyer trying to schedule a closing and some seller saying “we need to close on Monday.” And then on Tuesday, our lawyer called. They don’t want to sell after all. Or they do, but with some side shenanigans that you could call legal gray areas or you could call fraud or you could just call going out on a limb for a stranger. Whatever you call it, whenever someone says “you won’t get in trouble, no one has to know” that should be a sign. Especially when your lawyer says that it is probably a bad idea. It is a funny kind of extortion. They know we’re invested in the place and want to get this done. Maybe no one would ever find out. But beyond the fact that we want this place we don’t gain anything but anxiety and the thrill of knowing we’ve perpetrated a grand fraud. See what I mean? Bad idea.
So we have a choice. Sue them, or walk away. Walking away means starting over, hitting the streets again. A new inspector (cha-ching), a new lawyer (cha-ching), a new mortgage application (cha-ching). Another round of visiting the house ten times to figure out just how bad the mold in the basement is. But suing them means dragging this out. Paying a lot more to a lawyer (cha-cha-cha-cha-ching), tightening the screws on some people who are basically destitute already. Maybe it means that we never get the house because they pull some trump card out of their hat (maybe they aren’t bluffing about the licensed contractor they owe a bazillion dollars to who is going to put a lien on the building any day now). Or maybe it means that in six months or a year (or, as our lawyer has warned us, two years) a court will say “okay people, enough of this.” There are a lot more details (obviously) and if you want them you have to buy me a beer.
A few weeks ago, though, when this was all going swimmingly and we had every reason to believe we’d own the place by now (every reason) I told my friend P. that he could stay with us for a while. Now we don’t have space for him, especially not with my parents coming out here to help us pack. I don’t really know what they’ll be doing out here now, either.
He’s trying to get settled in New York, he isn’t working yet, not consistently enough to pay rent. And he was counting on us, so I’d really like to hook him up. So if you need someone to feed your cats for a week or two, maybe walk your dog. Or just water your plants and kind of make the place look occupied, let me know. He’s a good guy.
Also, since what I’ve learned from this whole experience is that even the nicest woman can turn out to be a conniving liar and a cheat, you could also restore a wee bit of my own faith in humanity here. I mean, there are people who will do you a favor just because they’re nice and you need a place to stay for a few weeks, right?
learning, linux, openoffice, technology
In various on July 15, 2008 at 10:12 pm
I’m monkeying around with OpenOffice and VLOOKUP and HLOOKUP and just LOOKUP. I have a spreadsheet with a column of values like:
FRIENDS OF REESE BERMAN
COMMITTEE TO ELECT MIKE FLYNN COUNTY CLERK
LIMA DEMOCRATIC PARTY
FRIENDS OF ANDY TORRES
COMMITTEE TO ELECT PETER A TULIN
COMMITTEE TO ELECT PETER TRIPODI
FRIENDS OF ROBERT H. GIZA
FRIENDS OF BRANCATI
ALPAC (ALCAS POLITICAL ACTION COMMITTEE)
FRIENDS OF YONEL LETELLIER
And a spreadsheet with columns of values like …
Reese Berman
Ed Brancati
Mike Flynn
Robert Giza
Yonel Letellier
Andy Torres
Peter Tripodi
Peter Tulin
And I want to connect “COMMITTEE TO ELECT PETER TRIPODI” to “Tripodi, Peter”. MATCH will take regular expressions but I can’t quite figure out how to combine a cell reference with a regular expression.
Actually this works: =MATCH(CONCATENATE(".*";C2;".*");$A$2:$A$11;0)
Where C2 is the candidate’s last name and A2:A11 is the array of committee names. So I’m getting somewhere.
Giving up, am I. This helps:
IF(ISNA(INDEX(Sheet1.$B$1:$B$788;MATCH(CONCATENATE(".*";C24;" ";B24;".*");Sheet1.$B$1:$B$788;0);Sheet1.$B$1:$B$788));INDEX(Sheet1.$B$1:$B$788;MATCH(CONCATENATE(".*";B24;".*");Sheet1.$B$1:$B$788;0);Sheet1.$B$1:$B$788);INDEX(Sheet1.$B$1:$B$788;MATCH(CONCATENATE(".*";C24;" ";B24;".*");Sheet1.$B$1:$B$788;0);Sheet1.$B$1:$B$788))
command-line, learning, linux, postfix, technology
In various on June 5, 2008 at 4:53 pm
The Frankenserver walks again …
I finally figured out that the frankenserver, which serves web service for example.com and examplefoundation.org doesn’t know that it is not the mail server for these domains. The whole rest of the world knows it, but not the frankenserver.
I’m trying to figure out the right way to tell ye olde frankenserver (or perhaps postfix) that mail must leave the house. To be more precise: if WordPress (or OpenX or Urchin) generates mail for amanda@example.com, that mail can be delivered to some other address as defined in /etc/aliases, but it can’t be delivered to amanda’s actual mailbox off on Dreamhost.
If /etc/aliases sayeth “amanda amanda@gmail.com” then mail generated on the server for amanda will be punted to gmail, no problem. But if amanda isn’t defined the mail evaporates into the ether (or something). I want postfix, locally, to know that it should treat mail for example.com like any other mail–look up its MX record and send it there.
I’m not sure how to convey that to Postfix, however.
command-line, learning
In various on June 5, 2008 at 3:13 am
I have this database all defined for postgres. It is complex beyond necessity. Waaay beyond necessity, and it is making me all mad. I’ve been commenting things out right and left just to get something to work somehow.
Because I’m so nice, I’m sharing with you, below, all 580 lines. You can see my mad commenting. What I really want to know is if there is an easier way? Why are these constraint references breaking down? I’m not used to constraints. Also, does postgres just not need commas?
Read the rest of this entry »
command-line, food, learning, scheming, sustainability, teaching
In various on May 22, 2008 at 7:12 pm
I’ve got two things up my sleeves:
- it’s what’s for dinner. When I was little, sometimes we were not allowed to ask what was for dinner. I never understood. Now I understand. Sometimes when you’re cooking dinner you don’t want to say what you are making because that could open the door to suggestions you don’t want to hear. Sometimes. Sometimes if I’ve been getting a lot of sleep and practicing yoga and capoeira and reading fiction and generally not stressing myself out, I don’t have this problem. My mother says that if I’m going to be nice to my eventual children I probably have to be less stressed out. She knows a thing or two, my mother does. Meantime, I’m thinking of starting a recipe blog about just eating food. Arif has one, it is pretty good. I’m secretly thinking of setting up a wordpress multi-author blog for the Clinton Hill CSA to allow lots of members to maintain cooking blogs.
- Hide and Sed with Reggie’s Ex or maybe Ask me anything, I’m a regular expert. Either way, you submit a question about whether it is possible to transform some heap of data and I’ll suggest a few ways to do it with regular expressions or Calc functions. Doesn’t that sound like fun?
PS, I don’t know why my stupid tag cloud doesn’t work. I can’t figure it out. I’ve tried and tried. Grr.
PPS, Speaking of eventual children (and no, this isn’t a veiled message or anything) some time ago I took to keeping eventual children at bay through a careful program of Fertility Awareness. I gave up eventually–it is one thing to take your temperature every morning at the same exact time if you’re trying to figure out why you keep getting your period when you’re looking to get knocked up. It is another thing to take your temperature every morning at the same exact time for five years with no end in sight just to avoid more conventional prophylactics. I’m glad I know a lot more about women’s health. I’m glad I put the thermometer back in the medicine cabinet, too. All of which is a big lead up to saying that Princess Melissa seems to be blogging again and since she is actively trying to get herself in a family way, her post on Fertility Awareness is hysterical. I think so anyway.
command-line, learning, linux, ruby_on_rails, technology
In various on April 22, 2008 at 1:56 pm
This is about programming, which only a programmer would know. Ruby is a programming language, rails is … rails. It is a library of code written in Ruby that you can hook all together in a row and make do things, quickly. So they say. Like so many things, most Ruby on Rails sites for beginners assume we all begin at the same place. I’m beginning at a place where this particular tip sheet is useful.
Our project is this: the Clinton Hill CSA has a database that works. It does things people need for it to do. I want to move it from its old host to our Dreamhost account, but since it won’t just launch, I need to understand what I’m looking at a lot better.
Soooo… Read the rest of this entry »
command-line, learning, linux
In various on April 21, 2008 at 3:33 pm
Assuming you’re using Apache. I’m using Apache2, so I can’t even promise this will work on 1.x. Assuming you’ve got a BSD or Linux system. I keep coming back to this and my own archives are so scattered it isn’t a lot of help.
You need two things:
1) A virtual host definition. Somewhere in the directory where your virtual hosts are stored, make another one. /etc/httpd/conf.d and /etc/apache2/sites-available are likely candidates.
2) A domain name defined. Here is where things get sneaky. You can put definitions in /etc/hosts, which I like to do for local domains. On our Rackspace account, I hafta head into Rackspace’s domain name manager to add a subdomain. I don’t know where that gets written to. There are probably another dozen ways to define domain names. These are the two I’ve been using that I keep trying to look up.
learning, technology
In various on April 8, 2008 at 7:50 pm
Who’s Running for What is live, and it happens to rule. It also (happens) to rely heavily on Javascript pop-up windows, which are a little unwieldy if you haven’t worked in Javascript for the last ten years.
Read the rest of this entry »
learning, linux, ruby_on_rails, technology
In various on April 7, 2008 at 1:08 pm
While back, Scott loaned me some Rails books. They’ve been holding up my bookshelf ever since. I have, however, inherited a working Rails app that I need to migrate to Dreamhost, so it is time for me to learn this beast, at least a little bit. Rabble made it look so easy, but I have no idea what I’m doing.
Here is what I’m slowly figuring out:
rails someapp will generate a stack of basic files that form the foundation of a rails application.
dispatch ./public/dispatch.fcgi and ./scripts/server seem to do about the same thing. In my case, they seem to generate the same run of errors:
[0 chcsa@karnov ourCSA]$ ./public/dispatch.fcgi
/usr/local/lib/site_ruby/1.8/rubygems.rb:317:in `activate’: can’t activate actionpack (= 1.13.6), already activated actionpack-2.0.2] (Gem::Exception)
from /usr/local/lib/site_ruby/1.8/rubygems.rb:335:in `activate’
from /usr/local/lib/site_ruby/1.8/rubygems.rb:334:in `each’
from /usr/local/lib/site_ruby/1.8/rubygems.rb:334:in `activate’
from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31:in `require’
from /usr/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:496:in `require’
from /usr/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:342:in `new_constants_in’
from /usr/lib/ruby/gems/1.8/gems/activesupport-2.0.2/lib/active_support/dependencies.rb:496:in `require’
from ./public/../config/environment.rb:54
from ./public/dispatch.fcgi:21:in `require’
from ./public/dispatch.fcgi:21
I think what the machine is trying to tell me is that my app is expecting a different version of a Gem called actionpack. Or (maybe?) my app is trying to activate gems but on Dreamhost they’re already active? Dreamhost has a list of installed gems that includes actionpack (2.0.2, 1.13.6). So the next concept I have to grasp is “activating” “gems.” I’ll be sure to let you know how it goes.
update Line 54 of config/environment.rb does say require 'action_web_service', while the list of installed gems shows only an actionwebservice. See what I mean about having no idea what I’m doing?
Actually, I think the next thing I have to wrap my head around is test, development and production environments. Am I supposed to setup three databases?
learning, linux, openoffice, teaching, technology
In various on March 25, 2008 at 1:50 am
=IF(AND(EXACT(E491;E490);EXACT(F491;F490));D490;SUM(D490;1))
You (we) are in column D with our formula. If column E matches the line above, and column F matches the line above, then use the value in D, above. If they don’t match, iterate up one.
That took me way too long to figure out.
art, artists, learning, local, NYC, photography, technology
In various on March 20, 2008 at 1:48 pm
If you work with teenagers, you probably know at least one that would love to be taking a black and white photography class, right?
Intro to Photography & Darkroom Technique
Ten Saturday Sessions
April 19 — June 21
11:00am — 2:00pm
This class will introduce the basic techniques of black and white photography: composition, exposure, film development, and printing, while exploring the documentary and creative potential of photography as a medium.
AGES: 14 to 17
FREE — Space is limited
For more information please contact Kate DeWitt at 212.254.3697 ext. 25
Registration form available at:
http://www.abcnorio.org/arts_ed/photo_registration.pdf
learning, teaching, technology, wordpress
In various on March 9, 2008 at 6:15 pm
From the mailbag, for the “no stupid questions” files, for the people searching the internets for answers.
i have a report back i’d like to post to the website but when i try to post pictures, i get the same message i asked about a week or so ago, i.e. “File type does not meet security guidelines. Try another.”
The pictures are smaller saved versions of the original jpeg files from my iPhoto download.
do you guys have suggestions?
Read the rest of this entry »
learning, linux, openoffice, software, ubuntu
In various on February 21, 2008 at 6:02 pm
Say someone gives you a spreadsheet full of names and addresses and you want to import them into a database that needs first name separate from last names. In Excel, one option is to split the cells along a delimiter. I forget how you do that, but it is a not-so-obvious option in the tools menu. Kind of cool, but if you have extra delimiters, you might end up with a million columns when maybe all you really want to do is take the last word as one column and the rest as another column. So Mary Lou Retton and Shannon Miller will come out as “Mary Lou” and “Retton”; “Shannon” and “Miller”. If that is what you want.
Not only does OOo Calc not have that particular cell splitting function anywhere that I can find, it isn’t actually quite what I was looking for anyway. Not yesterday at least. I had before me a list that went something like:
Quiroz, Alfonso (ID:1092-UN)
Recchia, Domenic (ID:LW-UN)
Rivera, Joel (ID:361-UN)
Sears, Helen (ID:SH-UN)
Simon, Brian (ID:1155-UN)
Bonus points if you can figure out where I got my data from. Here is what I did to get a column of IDs, where B92 is a cell that reads, say, Rivera, Joel (ID:361-UN):
=SUBSTITUTE(RIGHT(B92;SUM(LEN(B92);-FIND("(";B92)));")";" ")
Cool, huh? Oh wait, you probably think this makes no sense. How about this:
FIND("(";B92) — find the position of the opening parens.
LEN(B92) — get the length of the whole field.
SUM(LEN(B92);-FIND("(";B92)) — get a count of characters after the opening parens.
RIGHT(B92;SUM(LEN(B92);-FIND("(";B92))) — grab that many characters (grab all the characters after the opening parens)
SUBSTITUTE(RIGHT(B92;SUM(LEN(B92);-FIND("(";B92)));")";" ") — and then trim off that closing parens by substituting it with an empty space.
I got lazy after that and used a similar bit of function wizardry to pull out the names:
Quiroz, Alfonso
Recchia, Domenic
Rivera, Joel
Sears, Helen
Simon, Brian
And then I just used a simple little function to make last name and first name columns. The last names were:
=LEFT(B3;SUM(FIND(",";B3);-1)) — find the comma, paste everything to the right of it (or rather, find the position of the comma, subtract 1 to get the position before the comma, and then pull that many characters starting at the left.)
And for first names: =RIGHT(B3;SUM(LEN(B3);-LEN(D3);-2)) — D3 was my new last name column: get the character count of the last name and calculate the number of characters that are not consumed by the last name LEN(D3), the comma and space after it -2. We’re pulling from the right this time.
I realize that I haven’t documented this extraordinarily well, but I’m hoping it will at least help me in the future. Sorry if your poor eyes have gone and glazed over.
ps, is parens a word?
pps, why would I write something so useful and never once use the words OpenOffice or OpenOffice.org or even just OOo? I can’t search my own blog for posts about OpenOffice if I never say such things are here.
learning, linux, software, technology
In various on February 21, 2008 at 1:52 pm
I need a VNC client for Ubuntu.
The Ubuntu repository has 5 or 6, and I really have no idea how to distinguish them. Normally I’d hit up Social Source Commons, but I don’t see any Linux VNC clients there.
It looks like the difference between the options has to do with the display protocol. DirectVNC uses the “remote framebuffer protocol” while xVNC4Viewer uses X and sVNC “provides a client for SVGA.”
I’m lost. The package descriptions aren’t really helping: Read the rest of this entry »
art, artists, books, learning
In various on February 9, 2008 at 5:55 am
I have a sneaking suspicion that I’d like Josh’s poetry, ever since I found out about Glottopsychiatry. Other sneaking suspicions? Other people are having more fun.
Also, quiz (a survey, actually): what do you know about the ERA?
command-line, learning, linux, postfix, security, technology
In various on February 7, 2008 at 10:45 pm
Still kind of wondering if I could/should just close off smtp connections in an xinetd config, but tail /var/log/maillog seems to be saying that my little friend at 81.189.52.37 is having less success connecting of late:
Feb 7 17:35:59 s47822 postfix/smtpd[6537]: disconnect from unknown[81.189.52.37]
Feb 7 17:35:59 s47822 postfix/smtpd[6544]: disconnect from unknown[81.189.52.37]
Feb 7 17:36:00 s42782 postfix/smtpd[6523]: lost connection after CONNECT from unknown[81.189.52.37]
Feb 7 17:36:00 s42782 postfix/smtpd[6523]: disconnect from unknown[81.189.52.37]
Feb 7 17:36:00 s42782 postfix/smtpd[6538]: lost connection after EHLO from unknown[81.189.52.37]
Feb 7 17:36:00 s42782 postfix/smtpd[6538]: disconnect from unknown[81.189.52.37]
Feb 7 17:36:00 s42782 postfix/smtpd[6522]: lost connection after CONNECT from unknown[81.189.52.37]
Feb 7 17:36:00 s42782 postfix/smtpd[6522]: disconnect from unknown[81.189.52.37]
Feb 7 17:36:01 s42782 postfix/smtpd[6506]: lost connection after EHLO from unknown[81.189.52.37]
Feb 7 17:36:01 s47s42782822 postfix/smtpd[6506]: disconnect from unknown[81.189.52.37]
Or am I missing something? This is an interesting list of main.cf settings to investigate. And this is a rundown of what they actually mean. Does adding reject_invalid_hostname or reject_non_fqdn_hostname do anything for me?
command-line, learning, linux, teaching, technology
In various on February 5, 2008 at 11:28 pm
From the kid brother files …
Forgive me if you already know this command but if you don’t it is really handy. script will allow you to record every keystroke in terminal until you type “exit” (I think it object if you try to enter vi or pico or stuff like that). This is handy if you are trying to solve some problem or download some packages in the terminal and want a record of what you have done. (just type $script filename.lst and it will record your activities – I’m sure that if you don’t already know about the command you are smart enough to figure out the rest)
Right off the bat, some observations: are you really using vi and not vim? Did you know that you can usually look up the manual page of any command line linux goodness with $ man {command}?
And, if you’re using bash as your shell, your command history is stored in .bash_history. Try typing history at the command line.
My problem is this: in the shell you can hit the up arrow to scroll through your last dozen commands (sis note: that is the history I speak of above.) but script records all these up arrows and makes lines on the final document that are hundreds of chars long. So, is there a command that escapes this recording and just records the final command you settled on rather than the dozen you scrolled through to get to it?
It doesn’t look like script will let you do much besides log your keystrokes. What kind of packages are you downloading? I’ve been using aptitude over apt precisely because it does a much better job of showing you what you installed. Not that I remember off the top of my head how I did that or anything. But I did once. See such a list.
Are you downloading with wget? Try history | grep wget when you’re done downloading things. That ought to give you a good list of what you wgot.
Other fun facts? ctrl-r will search your history for you, so if you say ctrl-r and then start typing a command, it will offer you recent command history that matches what you are typing. Play with it. You can customize the number of lines that are stored in your bash history. Here’s that section of my .bashrc file:
# don't put duplicate lines in the history
export HISTCONTROL=ignoredups
export HISTCONTROL=erasedups
export HISTCONTROL=ignoreboth
# store more lines in history
export HISTFILESIZE=5000
# and don't store dumb stuff
export HISTIGNORE=pwd:exit:cd:ls:history
I think I drifted before I ever got the part about not logging duplicate commands to work as expected, but you get the idea.
command-line, learning, linux, technology
In various on January 30, 2008 at 10:27 pm
Another good reason to use ssh keys? My key is still on the server of a group I haven’t worked with in three years. I have no idea where I’d start looking for a password, but when the called me in a panic because their site had been “oWneD bY soM3 dw33b” I had no trouble getting onto their server. That might not be what you want, for me to be leaving keys under mats on servers the world over, but it is surely convenient. Passwords are tiresome.
Since I always end up having to look this up, here is a fun secret: for key based authentication to work, your .ssh directory usually needs to be owner only access:
chmod 700 .ssh
If you don’t know, now you know.
learning, technology
In various on December 20, 2007 at 7:48 pm
I’m not a very good sysadmin, or perhaps I’m the best sysadmin ever, but when I got here our server was sending out all kinds of spam. It was redunculous. I managed to cut a lot of it off, but I still see signs of the wolves circling at the door.
Dec 20 14:30:42 s47822 saslauthd[3997]: do_auth : auth failure: [user=fox] [service=smtp] [realm=s47822.example.com] [mech=shadow] [reason=Unknown]
Dec 20 14:30:42 s47822 saslauthd[3997]: do_auth : auth failure: [user=frank] [service=smtp] [realm=s47822.example.com] [mech=shadow] [reason=Unknown]
Dec 20 14:30:43 s47822 saslauthd[3997]: do_auth : auth failure: [user=giants] [service=smtp] [realm=s47822.example.com] [mech=shadow] [reason=Unknown]
Dec 20 14:30:43 s47822 saslauthd[3997]: do_auth : auth failure: [user=grace] [service=smtp] [realm=s47822.example.com] [mech=shadow] [reason=Unknown]
Dec 20 14:30:44 s47822 saslauthd[3997]: do_auth : auth failure: [user=gregory] [service=smtp] [realm=s47822.example.com] [mech=shadow] [reason=Unknown]
Dec 20 14:30:44 s47822 saslauthd[3997]: do_auth : auth failure: [user=hannah] [service=smtp] [realm=s47822.example.com] [mech=shadow] [reason=Unknown]
Dec 20 14:30:44 s47822 saslauthd[3997]: do_auth : auth failure: [user=hendrix] [service=smtp] [realm=s47822.example.com] [mech=shadow] [reason=Unknown]
Dec 20 14:30:44 s47822 saslauthd[3997]: do_auth : auth failure: [user=hola] [service=smtp] [realm=s47822.example.com] [mech=shadow] [reason=Unknown]
Dec 20 14:30:45 s47822 saslauthd[3997]: do_auth : auth failure: [user=howard] [service=smtp] [realm=s47822.example.com] [mech=shadow] [reason=Unknown]
And I’m contemplating shutting off all outgoing mail from The Box. The box only sends two kinds of mail: messages to me about how its day went and “tell a friend” messages when someone likes an article.
I don’t have a question or an answer, but I do want to know how to assert more control over who and what can use SMTP on this server.
learning, teaching, technology
In various on December 12, 2007 at 1:07 am
I’m looking for the cleanest and most reliable way to undo what Word so kindly hath wrought. Curly quotes begone. And I need it to be easy, because it is not for me.
Here’s the situation: we get lots of text coming in from all kinds of places. Usually, for the most part, it comes as Word documents. We’re a scrappy and scattershot operation and we don’t have any formal workflow. Editors edit, and our art director who is also an editor takes their MS Word files, copies into Dreamweaver, formats links and paragraphs and the dumps Dreamweaver’s output into our home-brewed content management system.
In house editors all have AutoFormat turned off, but we still end up introducing a lot of curly quotes and em dashes. They come in articles submitted by freelancers, or they come when someone is writing from home and hasn’t turned off AutoFormat or I don’t know where or how, but they just keep coming. And they break things up all over the place.
So puzzle 1 is how to handle that. I’ve been advised that one can search for straight quotes " in MS Word and Word will find curly quotes, so I ought to be able to write a quick macro that will clean up articles. A good first step. What I really need (want?) is to set something up that will automate the HTMLification process overall. The guy who does it doesn’t complain, but he does it totally manually and there is no reason that it can’t be scripted (and curly quotes removed in the process)
Puzzle 2 is this: in addition to em dashes and curly quotes, we do occasionally use accents in articles and emails. I’m slowly wrapping my head around charsets and, um, stuff. Because I’m pretty sure I need to understand them better in order to address this.
Later I’ll be meeting “sir yoda” to buy his router. For now, I’m having a hard time getting on line (it is cold in the study and I’m pretty sure my mother has cheese and olives out downstairs that I could be partaking of if I weren’t off in the cold study) so until I buy Yoda’s wireless router off of him (go Craigslist) I’m leaving you, dear readers, with a seriously half assed post.
And, for the loyal among you who are following this closely, dad is moving to rehab sometime tomorrow. Still a long climb ahead but for now we’re done tearing our hair out and wondering how much worse it is going to get. The new question is, how long is he going to stay like this before he starts to get better. They say he’ll be fine, they just don’t know when.
learning, linux, ubuntu, whining
In various on December 5, 2007 at 1:37 am
Sometimes, especially in website work, you want to make a lot of changes to a lot of files, all at once.
If you use Textpad this is a fairly straightforward proposition. If you use BBedit, same story. If you’re a linux user, though, you are kind of up a creek. KFileReplace is just plain weird. It can’t do multi-line searches. You can’t actually store or edit search patterns. You can store parts of them but then you can’t really retrieve those in any kind of logical way.
What I want to know is not why KFileReplace stinks. It is okay, it just doesn’t really do enough. Their help files contain the rather mind boggling dismissal of regular expressions:
If you want search for every string that starts with “x”, “ht” or “u” and ends with “ml”, you can write a regular expression like this: (x|ht|u)ml. Insert this expression in the search editor, click OK, and enable regular expressions by toggling the Regular Expression button. Please note that using regular expressions lets you to make very complicated searches, but the cost could be a performance degradation. Regular expression can be very tricky, and it is often the case that “if you want to solve a problem with a regular expression, you have two problems”.
So I get where they’re coming from. What I don’t understand is how it is possible that people using GNU/Linux don’t need to do batch, multi-line, regular expression replacements. Is this just a web developer thing, and web developers haven’t historically used Linux? Is this a sign that I’m not a real programmer, my desperate need to find and replace across 44,000 documents?
Am I missing something?
command-line, learning, linux
In various on November 26, 2007 at 4:10 am
I haven’t posted about wrangling with computers in a while because I haven’t really been wrangling with computers lately and people seem to take offense when you go and post about how infuriating they can be (at least as infuriating as software) so I’ve been mostly keeping my mouth shut.
Now, though, subversion is trying to kill me and causing me a headache and I find that when I post about these headaches here, one of two things happens. Either I figure out the problem in the course of posting and maybe post it anyway, maybe don’t. Or someone else reads my whining and offers me some fruitful suggestions. Or nothing happens, which would be three things.
I did something screwy and then tried to undo it and that didn’t work so I tried to redo that and undo something else and I didn’t really keep an especially careful accounting and now I’m basically screwed. That is kind of an overstatement but at the present moment my repository is all busted up and I don’t know how to fix it.
First off (not first off, but I think this is the small thing so I’m starting here) I’ve got a directory (/html/games/incs) that seems not to have a .svn/tmp directory. I don’t see one, and when I do …
[somebody@someplace incs]$ svn cleanup
svn: Can’t open directory ‘.svn/tmp’: No such file or directory
[somebody@someplace incs]$ mkdir .svn/tmp
[somebody@someplace incs]$ svn cleanup
I was going to say that I know I have permission to create .svn/tmp but then I went to check and lo and behold, not only can I create the dang directory but that problem looks solved. Sweet. Okay, onto the next one.
PS, In case it is eating at you, I know that my whole tag situation is all busted up. I don’t have any plans to fix it because I just don’t. I think about it. I know I ought to, but you can assume that I’ll be mailing my mother’s birthday present first and since that is sitting on my desk more than a week post-due … you do the math.
So, um, huh?
command-line, learning, linux, ubuntu
In various on October 17, 2007 at 8:57 pm
Hypothetically, lets say your (GNU/linux) computer is choking. Sending errors about disk space, perhaps. Maybe a message from the mail server about /var/mail being full up, maybe a little pop up on your desktop that says “warning. 100% full”
Since Stillwell is the second machine in so many weeks to fill up on me, I’m going to rehash what I learned from Ignatz’s overload finally. And I won’t get surly, promise.
First question: is it really full?
[0 amanda@stillwell ~]$ df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda2 2.9G 2.7G 0 100% /
varrun 189M 128K 189M 1% /var/run
varlock 189M 0 189M 0% /var/lock
procbususb 189M 108K 189M 1% /proc/bus/usb
udev 189M 108K 189M 1% /dev
devshm 189M 0 189M 0% /dev/shm
lrm 189M 33M 156M 18% /lib/modules/2.6.20-16-generic/volatile
/dev/sda1 99M 5.6M 89M 6% /media/sda1
/dev/sda5 30G 8.3G 20G 30% /home
/dev/sda6 30G 1.2G 27G 5% /mnt/vartemp
That would be a yes. If you want to talk about my freakadoo setup with /mnt/vartemp, you can, but in my book that is a story for another day.
Assuming I haven’t been paying attention to my computer, here is what I know from this report on my file system disk space usage: /home is on its own partition. So that isn’t the problem.
Also, I happen to know that /mnt/vartemp is where /var and /tmp live, though I had to place them there and then use symlinks to overcome a quirk of Ubuntu that creates trouble if /var isn’t on the root partition (grammar check anyone? better link?)
So I’ve confirmed the sensation of fullness. Now what? Maybe I want to see just what is filling things up.
[0 amanda@stillwell ~]$ sudo du -kx | sort -n
Ahoy, but that shows files in my home directory. Riiiight.
[0 amanda@stillwell ~]$ cd /
[0 amanda@stillwell /]$ sudo du -kx | sort -n
69188 ./lib/linux-restricted-modules
93636 ./usr/share/icons
103192 ./usr/lib/jvm/java-6-sun-1.6.0.02/jre/lib
104748 ./usr/lib/jvm/java-6-sun-1.6.0.02/jre
104784 ./usr/lib/jvm/java-6-sun-1.6.0.02
104792 ./usr/lib/jvm
114764 ./usr/share/fonts/truetype
127596 ./usr/src
131012 ./usr/share/gnome/help
131432 ./usr/share/gnome
134208 ./lib/modules
139804 ./usr/share/fonts
145572 ./usr/share/doc
153164 ./usr/lib/openoffice/program
190152 ./usr/bin
220580 ./usr/lib/openoffice
225204 ./lib
1019328 ./usr/lib
1066040 ./usr/share
2438632 ./usr
2720781 .
Nothing special there. I suspect that I just set the partition too small (‘specially since I was installing Amarok when it choked.) Next question? Was I smart enough to use LVM when I built this machine?
drupal, learning, linux, teaching
In various on October 12, 2007 at 3:40 pm
Dear readers, I want you to know that you fall in two discreet and vociferous categories. Some of you sit on front porches and share your beers with me and tell me that you do read this notebook, but that you do not understand so much of it. Or do not want to. Others of you, you also share your beers with me, but you tell me that I do not document enough. That I should document more.
This one is for the second set. Read the rest of this entry »
learning, technology, various
In various on October 4, 2007 at 4:22 pm
My butt hurts. Or my hip. Haunch? My haunch? That is the extent of my personal communication for the day. That and that my butt hurts. Did I already say that? Making appointments, I swear. One with Fan and one with Dr Minkowitz.
Next item: ensuring email deliverability …
In addition to not running my own mail server, here is what I am doing to ensure that mail we send out actually gets to people:
* We defined a sender policy framework for our domain. Loosely, that means that we’ve spelled out the different mail servers that send mail for our domain.
* We’re cleaning up our HTML, and looking at help pages like this one from What Counts to help us figure out what to do.
I’m looking for other resources on good practices for HTML email content.
command-line, learning, linux, ubuntu, various, whining
In various on September 19, 2007 at 4:45 pm
I realized that I do have a smallish file that I’ve been tinkering with that would do for these purposes: We’ll call it SVG Sample.
I’m still annoyed that there isn’t any documentation of how Dia handles SVGs, but I’ll get over that. Or I won’t, but either way it is my problem, this inability to let go of small, small things.
Dia’s diagram tree shows exactly one thing (object? Is it an object?), “Standard Image” — it displays the various nodes all assembled together as a single image. It doesn’t recognize this as a group of images.
Inkscape recognizes the individual objects (nodes? are they nodes?) but fails to recognize the edges as connectors.
Kivio asks me to “select a filter” from the options “Kivio Document” and “XML Document.” The first (not surprisingly) fails with an error along the lines of “this isn’t a Kivio document” which is cool. We’re all on the same page so far. The latter filter then wants me to import an XSLT configuration but doesn’t show me any I can import. Not exactly a brick wall, but it isn’t getting me anywhere, either.
command-line, learning, various, whining
In various on September 14, 2007 at 9:33 pm
Inkscape.
Create an SVG flowchart in Graph::Easy, save the .svg and open it in Inkscape. Ungroup.
That is all. I was trying to do this in Dia, which was making me crazy because it wouldn’t let me ungroup the vector graphics that made up my flowchart.
command-line, learning, linux, ubuntu, various
In various on September 14, 2007 at 4:26 pm
Tinkering with creating a bootable USB disk with which to install Feisty on Brahms. Tried on round of effort and got to a boot error.
One how-to at my disposal suggests repartitioning the stick with cfdisk /dev/sdb
That got me to this fine error FATAL ERROR: Bad primary partition 0: Partition begins after end-of-disk Press any key to exit cfdisk, which I’m going to call helpful. Something didn’t work as planned.
Meanwhile, Oates can’t chop up a PDF in Acrobat Reader, but I can, because I’ve got pdftk. Which he could get, but I digress.
I got started, but realized I wasn’t naming things the way I ought and (of course) got to wondering why I don’t know how to use regular expressions in mv. If you want to take everything named *.pdf and rename it ABBR_{originalname}.pdf … how often do you want to do that? At least once every six months, right? So it is worth spending twenty minutes looking for a regular expression syntax that will save you a half a second. Right? (Please agree with me. I don’t know how I’ll handle it if you don’t …)
[0 amanda@stillwell ~]$ for f in *.pdf; do mv "$f" "ny_${f%}";done
It is a good starting point for doing more interesting things. Fortunately, I’ve done what I needed to do and I might never come back to this wee bit of shell scripting.
learning, linux, technology, various, whining
In various on September 13, 2007 at 7:59 pm
As long as I’m suffering, puzzling through trac installation, I may as well lobby for some votes.
Look here, friends. If you use Dreamhost, you know you can vote for things you want them to do. I don’t really know whether they count votes or just do this to make the likes of me feel better, but on the off chance that our votes are counted, maybe you’d consider doing me the immense favor of casting your vote for one-click installs of Trac?
What do you say?
Here are a couple of other suggestions presently in the box that I think could be helpful to the likes of me who’d like to be using Trac on Dreamhost:
learning, linux, mapping, technology, various, whining
In various on September 11, 2007 at 8:16 pm
I’m puzzling madly over this.
How to get a chart to move over, then down. And over. Then down. It should be straightforward, but I can’t work it out. I’ve tried a lot of things. Read the rest of this entry »
learning, linux, technology, various, whining
In various on September 7, 2007 at 8:19 pm
Without getting too deep into why I can’t use Visio (I don’t have MS Office) or OmniGraffle (They don’t make that for Ubuntu) or Dia (I’m fussy), I settled on Graph::Easy because I am a dork and thus anything that you install via CPAN …
So you have a million manuals and even a cool demo site, so I know that my text works fine. Yay. Read the rest of this entry »
command-line, learning, subversion, technology, ubuntu, various
In various on August 7, 2007 at 6:15 pm
Having thoroughly fouled up a repository in the process of trying to upgrade WordPress, I’m returning to the original project: nest my SVN repositories. I suspect that it is going to be easier than I originally thought. Starting with a broken repository, it goes like this:
Confirm that shit be haywire with …
[0 amanda@stillwell blogs] $ svn status
Move your wordpress files out of the way for safe keeping:
[0 amanda@stillwell blogs]$ mv wordpress /home/amanda/Desktop/wordpress
Try an svn cleanup without the stray directory:
[0 amanda@stillwell blogs]$ svn cleanup .
Now that things are unlocked (still not unlocked? You need the book.), get the original out of SVN (it is already gone from the filesystem, since you moved it)
[0 amanda@stillwell blogs]$ svn delete wordpress
[0 amanda@stillwell blogs]$ svn commit
Now, you’ve got a halfway clean slate and you can…
svn co http://svn.automattic.com/wordpress/branches/2.2/ wordpress
Copy your themes, plugins, wp-config.php and .htaccess over from your back up (or get new ones, if the new version requires them — don’t forget to think for yourself here …) and then get them talking to your original repository. You might even want to read the official instructions for more info on what you’ll want to keep.
We aren’t done here and I’m not convinced that this is going to work. Sigh. What I ended up with is three directories in “blogs” — plugins, themes and configs — that are part of the repository that I manage. So those are in my general repository’s subversion tree (is that a sentence?). I have copy them over to where they need to be in wordpress/wp-content/ when I change them. So there is a manual step, but we’re a lot closer than we were before. I am anyhow. Can’t speak for you.
You get the idea. If you don’t, you should do some reading.
Moving right along, both phpMyAdmin (which makes you weak) and Spam Karma 2 are inexplicably committed to opening some (but not all) php files as external documents. Blank ones. I blame my Apache config, but it still makes me tired.
PS. why, oh why does neither of these lines:
export HISTCONTROL=ignoredups
export HISTCONTROL=ignoreboth
effectively prevent my bash command history from logging a zillion duplicate command?
command-line, learning, linux, ubuntu, various
In various on August 3, 2007 at 8:50 pm
I use grep a lot to backtrace through the layers of includes that make up the site I manage, and since I’ve now got that site halfway into version control, I’m finding that I’m a wee bit frustrated because grep -r recurses through every directory, including the .svn folders. So I get a lot of extra responses. I want to tell grep not to look anywhere down the .svn path.
Or, perhaps, is there another tool I ought to try?
command-line, learning, linux, ubuntu, various
In various on July 30, 2007 at 5:53 pm
I know, I know. I promised about the puns. I’m not even frustrated.
Project du jour: version control with dreamhost one-click installs. When you update an installation using the Dreamhost control panel, Dreamhost moves your old files from directory to directory.old, and installs the update in directory. If you want these new files in subversion, you have to scoot all the existing .svn directories back into directory.I’ve never (really) written a shell script from scratch before and this seemed like a good place to start.
With the help of an indispensable overview of advanced bash scripting published by the Linux Documentation Project, I got this far:
#!/bin/bash
path=/home/username/staging/blogs/
oldblog=someblog.old
newblog=${oldblog/.old/}
directory=$path$oldblog
for file in $(find $directory -type d -name '.svn')
do
echo mv $file ${file/$oldblog/$newblog}
done
exit 0
I find all the .svn directories and print out a close approximation of the command that I want. A close approximation. What I still need to do is strip off the last .svn so that the result will look more like:
mv /home/username/staging/blogs/someblog.old/.svn /home/username/staging/blogs/someblog.old/
Once I’ve got that down I can actually execute the command itself instead of just writing it out. I think I’m missing something syntax-wise (I know it is in the manual someplace …) and while I puzzle over it, I need to move on to other things.
Still, if you’ve got feedback or a better way (more elegant? more right?) I’m all ears.
For bonus fun, my bash environment on Dreamhost insists on writing long commands to a single line. Why? I can’t read that shit.
command-line, learning, technology, various
In various on July 23, 2007 at 3:25 pm
I need to learn to resist puniness in my post titles, but I haven’t yet learned. I’m learning a wee bit about DNS, from dkg, because I’ve got some domains around that our local DNS server isn’t resolving properly. Or wasn’t. Now they are, but later, when they aren’t again, I’ll want to come back to this.
Here’s what dkg had to say: If the DNS servers offered by the DHCP server on your LAN are giving stale info, it’s probably worth tracking that down and reporting it.
Here are some handy ways to do it:
first, document that the suspect DNS server is giving the wrong IP address:
SUSPECT=x.y.z.w
KNOWNGOOD=4.2.2.1
QUERY=foo.example.net
dig @$SUSPECT $QUERY
dig @$KNOWNGOOD $QUERY
Or, rather:
dig 192.168.1.3 gothamgazette.net
dig 4.2.2.1 gothamgazette.net
then, you might also want to ask the authoritative nameserver for the relevant domain:
dig ns @$KNOWNGOOD $QUERY
dig ns 4.2.2.1 gothamgazette.net
if $QUERY is third-level domain (e.g. foo.example.net, instead of example.net), it may not give you an answer, but instead might give you an AUTHORITY section instead. You might then want to re-run the nameserver query against the second-level domain (e.g. example.net).
Having learned the authoritative nameserver for the domain, try querying that nameserver directly:
AUTHORITY=(fill in response from the dig ns here)
dig @$AUTHORITY $QUERY
dig ns1.dreamhost.com gothamgazette.net
does it match the answers from the known good DNS server? does it not match the answers from the suspect server?
pay attention to the TTLs of each response, also. It’s entirely possible that the suspect server legitimately cached an old value, and it is just waiting for the TTL to expire. Do subsequent requests to the suspect server decrement the TTL properly? The value should be in seconds.
Try the suspect server again when its published TTL has expired. Does it still give the bad answer? If it does, you might want to look up who controls the nameserver, either by PTR record:
dig -x $SUSPECT
or by whois allocation record:
whois $SUSPECT
If the nameserver is giving out bad information, it might be worth telling the tech or administrative contact of the controlling organization that they’re offering substandard DNS service.
It’s also worth publishing a note about in a blog (or somewhere similar) with concrete details so that other people who find they have similar trouble with the same providers can be assured that they aren’t crazy.
Note that your nameserver might be run locally, possibly in a NAT’ed RFC 1918 address. In that case, you should contact your local adminstrator about the problem. If you *are* your local administrator I’m not. Whew!, you should either repair the nameserver, or fix your DHCP service to suggest a functional nameserver in the DHCP Options (option “domain-name-servers” in ISC’s dhcpd.conf, identified by tag 6, according to the offical DHCP parameters spec [0]).
The nameserver is local, a Windows 2003 server. I’m probably the only one on the network paying close enough attention to be frustrated, but I’ll still post here …
command-line, learning, linux, ubuntu, various
In various on July 13, 2007 at 10:07 pm
Two projects I’m stuck on as Friday draws to a close…
First off, importing the GG site into my new subversion repository craps out when it gets to a particular folder:
Adding /some/path/parks/index.shtml
Adding /some/path/parks/learn.html
Adding /some/path/parks/flash
svn: Valid UTF-8 data
(hex: 2e 5f 50 6c 61 74 65 6c 65 74)
followed by invalid UTF-8 sequence
(hex: 99)
flash is a directory that contains one .fla file, one .swf file and a font directory called Platelet? (yup, with a question mark. I have some ideas about why it is crapping out, but nothing solid. I’d really like me some version control.
[update:] I couldn’t post this without trying a few more tidbits. There was a hidden file (some OSX detritus) that contained an extended character. So that is solved.
Also, (perhaps I’ll fix this before I finish blogging, too) I’m puzzling over the right way to enable remote access to mysql. Along with my fancy pants version control, I’d really like to periodically make a copy of the live database. Or to periodically update my local copy of the database with newer data. Something like that. It is a one way transaction. My options, as I see it, are: mysqldump, mysqlhotcopy and replication
Replication seems excessive, but I could be missing something.
I think hot copy is all I need, but I’m now confronted with the secret truth: I’ve never setup a mysql server before. Not properly anyhow. I don’t know where the settings hide that I need to make mysql accessible over the big bad internets, via a domain name. I don’t know exactly how to do that securely (limit connections by originating IP address?).
I know that I need to change the bind-address setting, but …
* I only want to allow connections from a finite number of IP addresses, and
* I’d like to limit the users who can connect remotely.
[update]: that was actually really easy, too. As it turns out, mysql was already accepting some external connections. The rest is just a matter of GRANT syntax.
learning, news, politics, technology, various, whining
In various on June 16, 2007 at 1:36 pm
Before I signed up with Constant Contact I asked around a bit. The consensus seemed to be that no one much cares for them and no one can really articulate what is so wrong with them.
One woman (alternative energy, DC. Her card is on my desk at work) said that you couldn’t slice and dice as much as she wanted. Fair enough. We send a lot of emails and didn’t really need to slice and dice that much. For what it is worth, it is pretty hard to slice and dice at all. She did have a point.
Now that we are thoroughly off of their platform, I thought that others might benefit from a brief run-down of why Constant Contact did not work out for us. For one thing, their customer service is for shit. There are all kinds of questions that they must know the answer to, some where deep down, but they will insist, insist, insist that there is no answer. For instance …
- Their interface doesn’t work with Safari, for no good reason, and though they obviously are doing some browser sniffing they claim to be unable to provide any type of requirements or list of browsers that do work.
This is the catch: when you try to use Safari, you get a message saying that your browser won’t work with their software. It isn’t just that it doesn’t work, they’re doing browser sniffing and saying “Safari won’t work” explicitly. And they won’t tell you what they’re sniffing for. It is crazy making.
Safari incompatibility isn’t the end of the world except that our editor has something wrong with her Firefox installation (I haven’t looked at it beyond confirming that it sure doesn’t seem to work.) and I just don’t think it is so much to ask to get a list of known good browsers.
- Their “compliance department” maintains a secret blacklist. Should you choose to link to someone who once wronged them, they’ll lock your account, not mention that your campaign was never sent, make you wait on hold for ten minutes and then tell you only that the linked URL is forbidden. Nothing else. No explanation of why it is forbidden, specifically. No apparent understanding of how unnerving it might be to have your account locked without warning.
And no, they can’t tell you who else is on the blacklist. You’ll just have to wait and see. At least one irreverent NYC newsweekly is on there, though.
After a fair amount of hemming and hawing, they did finally explain that the blacklist item we’d triggered was a former customer that had been using the system to spam people. You aren’t supposed to do that. Fair ’nuff. But all we did was link to them.
- While we’re on the subject, their interface is for shit. You can figure that out for yourself when you do a trial, but it certainly makes the list of reasons to use just about anything else.
And the slicing and dicing? It is pretty bad. Say you have a subscriber and you want to figure out why he gets three of everything. You’d want to search your lists for a particular contact, right? Good luck.
We’re on What Counts now and it rulez.
[tags]whining, technology, learning, politics, news[/tags]
Brooklyn, command-line, learning, linux, local, software, technology, ubuntu
In linux on June 15, 2007 at 1:31 am
N’s got a super-sketch-spyware-adware-trojan beast on his computer (that is what you get for browsing with IE, says I) — the kind of thing that you get from clicking the wrong button and launching some kind of ActiveX installer. It won’t go away. No amount of Spybot Search and Destroy or Spyware Doctor will make it go away (speaking of Spyware Doctor, later we can talk about how I feel that the Google Pack is all or nothing. What if I don’t want Google to take over my screen saver? Sure, I can uninstall it later, but why not let me choose in the beginning?).
We’ve given up trying to eradicate it, so I took a field trip to Mikey’s Hook Up where knowledgeable people took a break from their ping-pong game to ask me a few questions and point me towards a reasonably priced external hard drive so we can back up our home drives from his computer and start over. Got that? Knowledgeable people, enjoying their workday. I can’t tell J&R and Best Buy apart, but I am pretty sure that no one really tries to help you at either one. They sure don’t at Radio Shack. And you don’t get to play ping pong on your breaks at Best Buy. It is okay to shop someplace where the staff aren’t being forcibly crushed into a homogeneous model of “Perfect Customer Service” that involves no service whatsoever.
Back to the hard drive, though. I know that we could bring the malware with us, but, having evaluated the risk, we’re not that stressed out about it. Moreover, since the option is to just erase everything, we may as well try.
Since our fancy new LaCie (designed by Porsche, ooh la lah) drive has a gazillion gigs available, I get to back Brahms up, too.
Here’s what I did. I’d love to know if you’ve got a better idea:
[0 amanda@brahms ~]$ cd /media/LACIE/Brahms/
[0 amanda@brahms Brahms]$ sudo tar cvpfz backup.tgz --exclude=/proc --exclude=/lost+found --exclude=/mnt --exclude=/sys --exclude=/dev --exclude=/media --exclude=.Trash /
Note that Ubuntu mounted the drive of its own accord. It is not inconcievable that a person could have to mount a drive themselves if it doesn’t just automagically appear. If you don’t like my only relevant archive, you could try searching the internets.
I made up the “.Trash” part because I couldn’t find any documentation of how the tar --exclude option handles regular expressions. If I backed up the trash, okay, I backed up the trash. Worse things have happened.
Still, I’m wondering. Did I do the right thing? I created separate (duplicate) backups of a couple of directories where I store working documents (my home directory and /var/www/html but those were a little more straightforward.
PS, can i just tell you how much it warms my heart that Princess Oh-my-god-she-saw-me-without-makeup Melissa also is totally over ga-ga weddings. It isn’t just because I’m a difficult and belligerent punk, it is because people go out of their heads and they need to just not.
command-line, learning, technology, various
In various on May 24, 2007 at 3:55 pm
I’m taking a break from a puzzle I really don’t need to be spending this much time on. Here goes:
I heard a rumor that microformats are cool, and, I want to links to a calendar. Seems simple, and a good place to start understanding RDF. Here’s what I’ve got: the original calendar, which basically works for the time being; a script that pulls the links to the calendar (some of it, anyhow) into well formatted RDF (you’ll want to view the source, no doubt).
So, um. What do I do with that? I’ve been playing with some PHP scripts that will parse the RDF six ways to Shaolin but won’t just display anything I can display as html in the <a href=”URL“>Event Title</a> format.
I can generate a huge multi-dimensional array that doesn’t lump items together at all. I can generate a smaller array that only has the Titles and URLs, but they’re not distinguished in the array.
I need to sleep on it, because I think I’m missing something, either about RDF and parsing it or about PHP and arrays. Since I’m a long way from actual sleep, I’m hoping that you, dear reader, will chime in with some brilliant insights (a code snippet or two, perhaps?)
In the meantime, I did come up with a not altogether inelegant solution: I rewrote the script (the one that was generating well formatted XML) and now it generates a nice little HTML snippet. Now if anyone could tell me why this: my $feat_start = POSIX::strftime('%d,%m',@feat_field[0]); doesn’t work, or how this 2454232 is May 11, 2007 if it isn’t a date that strftime can work with … I’d be much obliged.
command-line, learning, linux, ubuntu, various
In various on May 16, 2007 at 4:07 pm
Once, these links helped.
windows clients can’t see workgroup (a post I made to a samba list) and Chapter 38. The Samba Checklist; Part V. Troubleshooting (a diagnostic walk through).
If you’re setting up a SMB network and hitting walls, start with Chapter 38, Part V.
art, audio, learning, letters_home, various
In various on May 16, 2007 at 2:07 pm
I recently had the opportunity to meet a famous radio host who happens to grossly overuse the phrase sea change. I hadn’t ever really noticed the trend in his show, but while I was in his office I overheard not one, but two show producers, interviewing potential guests on the phone, ask whether a sea change was afoot.
I thought I knew what the term meant, I even explained it quite confidently to my future mother-in-law (a bit more complex than simply when the tide turns, something about tidal estuaries) but then my upstairs neighbour asked me the same question and insisted that growing up on Puget Sound he’d never heard the term used to actually refer to tidal changes in the sound. We were looking for specifics when we discovered that the Famous Radio Host is wrong, as are so many more.
According to World Wide Words, the phrase comes from The Tempest
Full fathom five thy father lies:
Of his bones are coral made:
Those are pearls that were his eyes:
Nothing of him that doth fade
But doth suffer a sea-change
Into something rich and strange.
And has nothing whatsoever to do with tidal anything. Say what you will about normative linguistics and living languages. I’m jumping ship. I’ve always thought it was self indulgent to ask, over and over, “is this the moment when everything changes? what about now? or now?”
[tags]letters_home, art, audio, learning[/tags]
command-line, drupal, learning, technology, various
In various on May 14, 2007 at 1:49 pm
I’m goofing off with Contemplate, trying to play with displaying taxonomy terms in smarter and more structured ways. I’ve gotten as far as sorting out that (correct my syntax on this one, please!) Drupal node taxonomy is stored as a recursive array of objects. Here is one example: Read the rest of this entry »
command-line, learning, linux, technology, ubuntu
In various on May 10, 2007 at 7:09 pm
Used to be, I worked for Mainichi Shimbun, where I learned odd things, including that the Japanese term for “desktop” in the digital sense is “deskutoppo.”
I also don’t really understand why my computer crashes so much and I wish I knew more about command line WPA. It seems wrong to install things willy nilly. Read the rest of this entry »
audio, learning, software, technology, ubuntu, whining
In various on May 7, 2007 at 4:13 pm
It is no secret that I’m kind of flummoxed by audio on Brahms. I recently got annoyed enough to send a moderately unhelpful “someonehelpmefixthisplease” query to a list I’m on. I got some response to the tune of “read the Ubuntu forums” which prompted me to try a friendlier list (and to threaten any forum-deflectors with a swift kick to the shins). Maybe it was the threat of violence, maybe it was just that radical techies are good people, but I got some great responses, which I’m filing here for future reference.
Read the rest of this entry »
drupal, learning, technology
In various on May 1, 2007 at 10:09 pm
We’re in the process of moving ABC no Rio to Drupal, starting with the Visual Arts Collective.
We want to do exactly what you might expect that the Visual Arts Collective of a community center might want to do: show off work that appeared in recent exhibits.
Read the rest of this entry »
command-line, learning, linux, technology, ubuntu
In various on April 23, 2007 at 2:13 am
Used to be, I’d moan and groan a lot about how nothing since HomeSite has had a halfway decent regular expression editor. Made me cuckoo. Quanta only handles one line at a time, and don’t get me started about KFileReplace or I might have to tell you about how the helpfiles for regular expressions in KFileReplace, rather than actually explaining their RegEx syntax, basically just says that you shouldn’t use regular expressions. Wha?
But today, I learned about :arg and :argdo and I’m in vim heaven. See for yourself: http://www.vim.org/htmldoc/usr_26.html
[tags]ubuntu, linux, command-line, learning, technology[/tags]
learning, linux, technology, whining
In various on March 29, 2007 at 2:01 pm
I’m sniffing around for ideas on how to mount an OSX Disk image (a .dmg file) in Ubuntu, and I stumbled on this thread which has some other good Ubuntu ideas. I was tempted to ask there for advice, but apparently, before I’ll be allowed to comment I have to try out:
Audition to become a commenter. To become a registered commenter on this site, you first need to be approved by our team. We’re looking for comments that are interesting, substantial or highly amusing. So write a comment, polish up your words and choose a username and password below. Your comment will only appear once (or if) you’re approved.
I call bullshit on that, but it could be for the best. I think I can live without Lifehacker and they can live without me. Hmph.
So I’ll post my question here, where I’ve already passed the try-outs:
I want to mount an old OSX Disk Image, but it won’t just mount. I’m not really sure how to begin deciphering the missing piece. Is there a filesystem doodad to install? (speaking of which, what is the technically correct way to refer to a package like smbfs? It isn’t a file system, it is a thing that lets you read a file system. Not a utility either. So what?) OSX is based in FreeBSD so it can’t be impossible to mount .dmg files, but it sure isn’t obvious to me how to make it happen.
[tags]technology, whining, linux, learning[/tags]
command-line, learning, linux, technology, ubuntu
In various on March 16, 2007 at 3:10 pm
Used to be, I had a Mac. I complained some, I liked it some. Whoopee.
One thing it did that I liked, was it streamlined local name based virtual hosting. If you do any kind of web development, that can be pretty helpful, name based virtual hosts on your local computer. Now that I don’t have a Mac anymore, I have to do these things for myself.
Without a super full understanding of how Apache interacts with, um, other stuff, I got about as far as making a virtual host entry, knowing full well that I was missing something but not having the first idea what I was missing.
I finally buckled and talked to dkg who, of course, explained the fifteen different ways that I could get name based virtual hosts working locally. I opted for the /etc/hosts option, and added a line to my hosts file that maps “http://thisproject.local” to the loop back IP address 127.0.1.2.
The text of each file is below, but I’m still secretly stumped. I’m missing something about how this all works, as I never defined that IP address anyplace else, and while http://thisproject.local works just fine, http://127.0.1.2 still maps straight to /var/www/index.php.
Here is my /etc/hosts file (part of it, anyhow)
127.0.0.1 localhost brahms
127.0.1.1 brahms
127.0.1.2 thisproject.local
And here is the Virtual Host definition that I enabled (note that I store the actual website files in a way that I find useful, first by project, then by URL. Some projects have a few URLs.)
NameVirtualHost *
<virtualhost *>
ServerAdmin webmaster@localhost
ServerName thisproject.local
DocumentRoot /var/www/thisproject/www.thisproject.com
<directory /var/www/thisproject>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</directory>
ErrorLog /var/log/apache2/thisproject_error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog /var/log/apache2/thisproject_access.log combined
ServerSignature On
</virtualhost>
I’d love some help figuring out how to make this entry more accurate. I’m definitely still missing some things, but I like to writeup what I get working.
(While we’re on the subject of puzzles, Ultimate Tag Warrior seems to be choking somehow. Not sure what the deal is, but I did tag this article with “command-line, technology, learning, linux, ubuntu” and I bet those tags are going to get swallowed. I’ve upgraded WordPress a few times, so I suspect I broke something. )
command-line, learning, linux, technology
In various on March 14, 2007 at 3:48 pm
Continuing with my purely hypothetical project, taking over a server that I didn’t build …
I’m wondering about Yum. Say you’ve got a RHEL4 server, and there aren’t any functional package managers running (up2date is there, but that only looks for kernel upgrades) and you want some package management. I installed Yum from RPMs, but now that it is installed, I don’t have any kind of handle on who to trust for packages. There is no debian stable for RedHat.
I found good instructions on adding repositories to yum.comf, but no reliable advice on which repositories to add.
command-line, learning, technology
In various on March 14, 2007 at 3:35 pm
Say you’re responsible for a server, and you want to take a look at mail that this server is sending out. How do you do that? Hypothetically, lets assume that you didn’t build this server, you just took it over and are trying to reign in all kinds of ghastly nonsense.
First, you need to know what kind of SMTP server or mail transfer agent (MTA) you are running. Odds are pretty good that it is either Sendmail or Courier. If you really aren’t sure, try searching your running processes for either of those: ps aux | grep "sendmail".
Actually, it isn’t that vital to know, but it is useful information. What you really want to know is, what kind of mail is passing through your system.
If you have webmin, it is pretty easy to look through your queue. Just sniff around in webmin for something that looks like “Mail Queue” or something. No big deal. Webmin, however, makes you weak. I know you think I’m kidding about this, but I don’t kid.
If you like the command line, or you want to like the command line, try looking up the man pages for mailq. You might also want to take a look at your mail log (mine is in /var/log/maillog). You’d be amazed at what you find.
If you’re really new to the command line, you might want to learn a bit about bash operators to make this process easier.
Brooklyn, learning, money, real estate, scheming
In various on February 5, 2007 at 4:17 pm
A few folks have asked for this, and so I am sharing it. With you, my dear readers. Here is what I know:
Buying a home is usually a smart idea. You can use all kinds of rent vs. own calculations, but the big truth is that unless you own your home, you live at the whim of the rental market. I know very few people who have enough money saved to make a down payment on a home, and you can all consider this your consolidated lecture. Financial security isn’t magic. It takes planning and saving. I have never met anyone who regrets having put money aside, but I know a lot of people, some of them a lot older than me, who are suddenly confronting the precariousness of renting. One friend, now in his sixties, told me about how he used to think he was so smart, watching his siblings struggle to make mortgage payments while he lived in his shared home with his roommates and his super cheap rent. He was free, liberated from the guy lines of the banking industry. They were bougie suckers. Hah!
Fast forward twenty years, and he watched as his siblings paid off their mortgages right about the time that he realized he was tired of negotiating with roommates. Today, he can’t quite afford a home of his own, and he’s feeling a little stuck. He’ll roll with it, but he regrets not being more proactive when he had the chance.
Yes, real estate in Brooklyn is outrageously expensive. Almost as outrageous as San Francisco. That doesn’t mean you can’t afford to buy. Buy what you can afford and take it from there. Renting is a fine way to live in the short term, but unless you’ve got some kind of rent controlled love shack, you need to think long term. (and, even if you are rent regulated, do you really want to stake your financial security on the continued vigilance of DHCR? I wouldn’t.)
Right now, today, if you have good credit, 20% to put down and a verifiable and stable income, you can get a fixed rate mortgage at 6%. For every missing piece, the interest rate goes up a bit. Getting a morgage isn’t any more complex than that. A mortgage broker might be able to get you a better deal, but the real challenge comes when you don’t have good credit or a verifiable income or cash to put down. I don’t know how to help you with those things, I’ve always been a by the book kind of a woman.
If you are counting on rental income to pay the mortgage, the bank won’t let you count on more than 75% of prevailing market rents. They know a thing or two about real estate and tenants. Figure they are about right and don’t count on getting higher than market rents or never having any vacancies.
You can find a thousand articles about tenancy-in-common gone awry, but they all have one thing in common–people didn’t communicate and they didn’t put things in writing. Do business with people you trust, yes, but there is no better way to be sure that everyone is on the same page than putting it all in writing. Be real. Marriages fall apart after 20 years. 30 years. People change. If you are investing in a home, don’t just trust anyone. Trust people, yes, but seal your trust with a sign on the line that is dotted.
Mortgage payments are a complicated thing, but roughly figure this:
a=(P*(r/12))/(1-(1+(r/12))^(0-n))
wherein a= monthly payment, r= rate, P= principal (if you are feeling dense, that would be the purchase price minus your downpayment …), n= term in months (there are 12 in a year …)
Property Tax in NYC is an arbitrary beast, water is expensive, so is heat. Those aren’t minor expenses. The attached spreadsheet includes realistic numbers for a house I recently looked at, but you should do your own homework. The department of finance has records online, so does the Department of Buildings. Property Shark is a great resource, too.
(OpenOffice Mortgage Calculator | Excel Mortgage Calculator)
Confidential to JF, you can usually use some of a retirement savings plan towards the purchase of your first home. Might be only $10,000 that you can use, though. At one point recently I was looking at a chart that broke it down for me, but I can’t find it right now.
command-line, learning, linux, technology
In various on January 8, 2007 at 4:24 pm
Or was that Recovery Is Possible? For a bit more on using a live CD to rescue a machine, see my notes from January.
I had this fantasy (oh, what a fantasy) that puzzles like this were behind me, but I found myself, once again, staring at a wackadoo screen that was decidedly not Windows launching. Something about a boot disk and not being able to find one. Read the rest of this entry »
command-line, learning, linux, plone, teaching
In various on November 27, 2006 at 6:46 pm
I have good reasons for making this move and I don’t want to get pounced on for my decision, so let us just start there. My reasons include hosting costs and the fact that our Plone host hasn’t been a good fit. I recently completed the process of migrating Recycle-A-Bicycle to a new web host and CMS. I moved almost all of our content from Plone into Drupal, and learned a few things along the way. Read the rest of this entry »
learning
In various on November 21, 2006 at 8:15 pm
Little known fact: I used to teach grammar.
Other Little Known Fact: my friend Taylor used to say I reminded him of Clarissa on Clarissa Explains it All. I took great pride in that, even if he wasn’t actually being nice. I thought Clarissa was kind of cool, all things considered.
The question of the week this week is about my friend’s bikes. Or my friends’ bikes. Or my friends and their many bikes. How do you know if you need an apostrophe? Okay, if you think this is totally obvious and not worthy of a blog entry, consider yourself excused.
Read the rest of this entry »
audio, learning, linux, technology, ubuntu
In various on November 6, 2006 at 4:56 pm
I am continually mystified by sound and my laptop. It is one of the small handful of things that doesn’t just work and that drives me somewhat nuts. For the most part I can’t get any sound in Flash. That means I can’t watch YouTube. YouTube is primarily a distraction, I tell myself. I do not need YouTube, I tell myslf. But Arif just posted a piece about organizing videos online and I’d like to watch the KFTC video that he talks about. I’d like to hear the narrative while I watch it. I think that might be a good use of my time.
UPDATE: I forgot that half of what got me started on this is that I recently tried to explain to someone that I don’t get sound out of Flash and I did get sound at that moment. That really flumoxed me. And made me look silly.
I have more interesting audio projects that I thought I’d be working on, but if I don’t fundamentally understand how to control the audio on my laptop, I don’t know how much audio I’m supposed to do.
So that is a project for the coming weeks. I’m going to tackle the sound system and try my very best to understand it. If you already do, I could use some guidance.
command-line, learning, technology, ubuntu
In various on June 30, 2006 at 3:50 pm
Sorry dad, this one is definitely for the what the hell is she talking about? files. Maybe later I’ll write about sleeping under the cowitch tree and Frank Quan’s coffee and waffles and the Grace Quan, and that will be interesting. But for now, I give you …
Ubuntu Networking.
If you want to be able to use the internet and you aren’t a command line cowboy, these commands will help you find your way, since most Ubuntu How Tos expect you to know what kind of modem you’ve got before you set out.
lspci will list all PCI devices. Your internal modem and wireless card are probably still PCI devices. I had to scan the output for 802.11 because there was no mention of WLAN or wireless in the output.
You can also look under system > administration > device manager for a list of known devices on your system. Now that I know I’ve got an Atheros AR5212, I can actually get some useful information from the Network Manager hardware list
Most instructions aimed at making Network Manager work on Ubuntu instruct you to restart all the time. Since some instructions don’t actually work, you may find you’ve restarted for naught. Restarting takes a while, and if you happen to be, oh, doing anything else, you lose it all. And so I bring you sudo /etc/init.d/dbus restart: you can restart networking without restarting Ubuntu.
For what it is worth, what did finally work was to comment out most lines, ‘cept these:
# The loopback network interface
auto lo
iface lo inet loopback
in /etc/network/interfaces and then to restart. Then my wireless interface appeared in the Network Manager panel applet.
Next Challenge: dial up modems, pppconfig, wvdialconfig and more.
And then? Why did Knotes start leaving its Notifications Area icon floating on the desktop rather than docked in the Panel Notification Area? And how do I put it back?
Here is the deal: Knotes launches on startup. I like it, Gnome Stickes stink. For a while, it would launch and put its icon up with the other icons normally. Then one day the icon was floating off to the left and over the desktop. I quit Knotes and relaunched it and the icon went back where it belongs, but ever since then, when I startup the icon is floating in a very weird place on the desktop and not in the panel where it belongs.
PS, Dad, if you can figure Flickr out, you can upload somephotos of China Camp. That would be useful, don’t you think?
learning, linux, scheming, ubuntu, whining
In various on June 9, 2006 at 1:41 pm
This blog thing is handy, I tell you. Seems like I just put up a list of things on my mind and then total strangers (and some old friends, but it is the total strangers that get me) they tell me the answer.
So this week, on my mind, besides for “where can I have a massively large wedding ceremony in New York City without spending an arm and a leg?” is …
rss aggregator I want a free standing, pretty (yes, pretty) RSS aggregator for Gnome. I don’t want a mozilla plugin, I have one of those.
sendmail I foolishly installed sendmail because I was testing out Evolution, which I am here to tell you sucks, and it kept crashing (see what I mean? sucks.) and so I kept setting out to use bug buddy, which wants you to have send mail installed, or else it leaves this totally useless text file on your desktop and you still have to go through the bug reporting system, you can’t just upload the bug buddy report. So I was thinking “sendmail.” Also, since my ISP is touchy about ole port 25, I was having trouble with SMTP. In Evolution. Not in Thunderbird, which does not suck, and which works just fine. Okay, so I started installing sendmail and realized that I could spend a lot of time for no reason and I instead went about migrating to Thunderbird (below). Now, however, when I start up Brhams hits a few sendmail snags, launching sendmail (which was never configured). That annoys me, because it means Brahms takes longer to boot. So, do I just apt-get remove sendmail, do I configure it properly, or do I take it out of init.d (and what is the right way to do that?).
Thunderbird Fun fact: if you are handy with a command line, migrating to Thunderbird from Evolution is easy as pie, even if you are a person with many folders. You have to use the internets to find your Evolution mail folders, but then you just have to copy everything over to where Thunderbird wants your mail stored, and do a lot of deleting. (If you’ve already got Thunderbird running, you might want to be careful about this, you can definitely screw things up here at the Velo, Rapido school of hacking.) But what I did, was I moved all the mail files/folders from my Evolution folder .evolution/mail/local/ to my Thunderbird folder .mozilla-thunderbird/330inone.default/Mail/Local Folders/
and then went through and deleted everything with “ev-summary” or “ibex” or “cmeta” in the title (you can construct a nice “find” statement for that) When I was done, all my mail was where I expected it. Like I said, I am aces when it comes to trashing things, so take all my advice with a grain of salt. But most folks said it couldn’t be done, the Thunderbird migration. The only catch was that when I next downloaded my email, I got every message in my inbox anew.
wireless support in Ubuntu is weak I have a wireless network at home. It is password protected. The key is not somehting I can remember off the top of my head. I want to store it in my computer and come back to it, but basically everytime I leave Kohlrabi (our network) Brahms forgets the password. I don’t really understand why Gnome or Ubuntu can’t save network passwords. It should. It is freaking annoying that it doesn’t.
Ouch, that was Loud I need to figure out the sound stuffs on this computer. Partly, I just want it to stop beeping all the dang time, though I like the “you have mail” beep. What I really want, though, is to tell it *not* to pester me while I’m on Skype. Somehow, I want to be allowed to have Skype override all the other sounds on my computer so that I don’t have beeping while I’m on the phone. This one, I haven’t even looked at yet. Just so you know.
learning, linux, noise, technology, traffic
In various on May 8, 2006 at 9:41 pm
I’m working on a deadline, which means that I really am doing some hard core procrastinating. For starters, I am testing out forward track — it is sort of cool, but there is no way to tell whether or not someone actually followed through on their pledge to write to the mayor.
If you want to know the admin login, let me know.
If you are a flash expert, and you want to help me make it NYC specific, ditto. Let me know!
learning, teaching, technology
In various on April 3, 2006 at 3:23 pm
A lot of questions came up in Istanbul that I don’t have good clean answers to and that I have been mulling for a week now. One was from an organization that runs the Ukrainian Voice Portal. Voice as in voices as in activism and civic participation, not voice as in VOIP. Maybe that is obvious, to you, but I kept hearing “voice portal” and thinking VOIP. Similar things exist here, among them Democracy in Action and Citizen Speak (more on those below) and a range of variations in between and beyond (for tens of thousands of dollars you can do anything, but that end of the spectrum is so out of reach that I’ll let it slide for now). CivicActions and Development Seed and May First do drupal deployment work and can build you a site to do these things.
The folks from the Ukraine were asking some good questions, probably questions that any of the folks working on the projects above could help answer. Questions like “how do you measure the impact of a campaign?” both practically and theoretically. That is a question that gets asked a lot and one that advertising folks spend a lot of time thinking about, but that doesn’t mean I know the answer. I don’t think Drupal does very good tracking, though I’m open to dissent on that point. I know this is one of the questions Leda has been asking with dotOrganize, but I don’t think she’s got answers yet, not real succinct ones. What she’s got (we’ve got? I’m part of the requirements working group) is a lot of folks saying “yes, I need and no, I don’t have.”
I started to pull through a list of folks who’ve given this question more thought than I. I came up with these three:
April Pederson at Democracy in Action
Democracy in Action (or DIA) is a fee based site and service that provides a range of online campaign tools, from email blast services to letter writing campaigns and fundraising campaigns. Their system includes graphs so that a person can track responses to each appeal letter that gets sent out and see which are most effective.
Jo Lee at Citizen Speak
Citizen Speak is a much simpler platform than DIA, but it similarly allows users to track responses by how many people actually come to the site and sign each petition. Jo’s done a lot of thinking about how to improve the set up and I believe it is now available as a drupal module.
Jonah Paretti at Eyebeam Research and Development
Individually, Jonah has done a lot of really interesting work on tracking contagious media and Jonah worked on a project at Eyebeam called “Forward Track,” which allows you to map the spread of a campaign on a map. I believe they’ve only got it running on a US map but it is an interesting (and free/open source) project.
But I know there are more than that out there. Who is asking the right questions?
PS: confidential to Dad, I’ve started using a letters home category. You can limit your reading to tales of travel and other life adventures. Scott, Arif, if you get sick of the personal ramblings, I introduce you to the technology category.
command-line, learning, linux, technology
In learning, linux, various on February 27, 2006 at 8:07 pm
I just realized that Jack was looking around for this, which isn’t live yet. Wasn’t. Is now or you wouldn’t be reading it …
Got a Linux server but you don’t know your password? It happens. Usually it happens because someone set it up two years ago and since then it has just worked.
And then one day, for some reason, you couldn’t connect to the file share. One thing you can do is try booting with a live CD but if you just need to reset the password, you’ll need to first boot into single user mode. Because Linux is Linux, nothing is ever simple, starting with the fact that just knowing that you are running Linux doesn’t tell me what boot loader you are running. The boot loader is the program that loads when your computer starts up–this program, in turn, loads your operating system (er. actually it loads the kernel, which loads the operating system, but I don’t want to get ahead of myself). Windows comes with a boot loader, the Mac OS comes with a boot loader. Linux comes with a choice. The odds are good that your boot loader is either Lilo or Grub.
Briefly, from there, here is how you do it if your boot loader be grub and if your boot loader be lilo this’ll help, though I think that’s got directions for Grub, too.
learning, linux
In learning, linux, various on January 21, 2006 at 12:24 pm
I am still puzzling through this LDAP question. The question is roughly this: what is the right way to store my own phone book on a server so that I can access it via whatever address book is available to me on whatever computer I’ve managed to land in front of?
Most organizations I work with would use their databases more and better if they didn’t have to also maintain their email based address book in Thunderbird or Eudora or Outlook. Address changes would make it into the database and be shared across the organization if it were that easy. A database that needs a lot of other data about a person and what they’ve been involved in, that you’d have to access through a database interface, but the addresses alone could be LDAPish and that would be handy.
Catch is, I just don’t get it. I will, I just don’t yet.
For instance, it sort of seems like a webhost with a lot of LDAP libraries installed ought to be able to support an LDAP server. Seems like. Seems like if I knew where to start, I could start, but I don’t.
Slowly, over a very, very long stretch of time, I’ll get there. Hopefully when I do, I an leave a trail that will make a ton more sense to the next person than the crumbs I’ve been able to find.
command-line, learning, linux, technology, ubuntu
In learning, linux, various on January 19, 2006 at 2:01 pm
File under famous last words … sure, boot it from CD. Great. And then? What?
This, is what:
http://arainyday.se/notebook/windowsrescue.php
http://www.ubuntuguide.org/
More specifically:
The live CD boots its own operating system. If you want to access files on an existing hard drive, you need to find and mount that hard drive. fdisk -l will show you any attached disks (such as an internal hard drive) that can be mounted. sudo mkdir /media/windows will create a mount point or a place to find the hard drive in your linux file system and then sudo mount /dev/hda1 /media/windows/ -t ntfs -o nls=utf8,umask=0222 will actually mount the drive to be readable in that directory. If your old hard drive is FAT not NTFS, you’ll need a different command: sudo mount /dev/hda1 /media/windows/ -t vfat -o iocharset=utf8,umask=000 (fdisk -l should tell you how the drive is formatted)
Now you have to decide whether you are going to start by backing everything up. A bit of advice if you are actually trying to restore a fried system: you want to start by backing everything up. So, to back things up you need some kind of external drive. Probably a USB type of something, which you’ll need this handy command for: lsusb.
Which tells you that it can see that USB DVD-RW, but doesn’t tell you how to mount and write to it. I got tired of trying to figure that out, though I’m sure that some sequence of four commands would have gotten me up and running toot sweet.
Instead I went back over to the spanking new eMachine they’d bought, enabled a share drive (actually someone else had already done that part) and looked up its IP address (open a DOS prompt and give the ifconfig command). Then I enabled the ethernet interface (system > preferences > networking) and connected to it as a windows share (places > connect to server ... ; the service type is windows share, use the IP address of the destination computer in the server field.) and started copying things over and burning them to CD from the working computer. Not ideal since some kind of trojan horse is likely what brought down the old machine, but it works, and the new computer doesn’t have anything on it yet so this was safe enough.
Question for the kids at home: how could I have actually mounted the DVD writer?
learning, linux, technology, ubuntu, whining
In various on November 23, 2005 at 3:21 pm
It is the little things, you know?
Something, somewhere in this beastly machine ought to be able to tell me that a file is currently being edited by someone else. Instead, OpenOffice just crashes each time I try to save the document. That is bogus. It should know better.
learning, linux, various
In learning, linux, various on November 21, 2005 at 11:31 am
Slowly, and also quickly:
I was trying to mount a samba share so that I could access it from the command line. That is straightforward if you know what you are doing, but if you don’t, well. Welcome to the fog.
This is a useful thing that was hard to find: http://packages.debian.org — you can search for packages. If you can find fuse, and then you can get down to business:
sudo apt-get update
sudo apt-get install fuse-utils
sudo apt-get install smbfs
That was one of those things that everyone just seemed to assume I would know. “Just install it with apt-get” … install what? fuse? It isn’t there. smbmount? nada.
Now I know. Now you know, too.
sudo mount -t smbfs //downtown/Users /mnt/downtown -o username=[username],password=[pass]
Now downtown is in my path!
Oy, but I still can’t play MP3 files!
Back to the drawing board: I need gstreamer to play restricted file formats but just un-commenting the “multiverse” line in my /etc/apt/soures.list wasn’t enough to enable it. I was getting all kinds of errors so shamelessly followed this advice which helped me update my sources so that the gstreamer utilities would install.
Mmm. Food. Now I can listen to doom at work. Some people don’t even have to think about it, but look at all they miss out on!
learning, linux
In learning, linux on November 8, 2005 at 1:54 pm
We have a lovely, relatively new SuSE Linux server in our office and a SMB share that gets backed up regularly. I like to use it. You know, for sharing things. I had no trouble creating shortcuts to the shared directories that I use, but my head is going to explode if I can’t figure out how to get OpenOffice to show me what is in a shared directory before I save to it. Some times I can work around this and it isn’t so bad. I know where the file should go. Sometimes I am trying to save a grant proposal and I want to see if this is really the directory that it is supposed to end up in. I can see that by seeing what else is in the directory. I am not asking for the sky here.
On a related note, (related because I can’t just point to anything in my directory structure when it is really a smb share) I like vim (and I have to use it because I don’t like the text editors I’ve found so far for vim like things) and I want to be able to open some text files from the shared drive in Vim. I can open them in open office, but vim smb://server/Users/amanda doesn’t get me anywhere.
I heard a rumor that …
with older versions of samba servers, you can mount them in your fstab. there’s also something called FUSE (a userland file system space thing) there’s a lot of discussion as to whether or not user-space filesystems belong in the kernel. (ie, Linus says “no”) but I’d look for FUSE, and also I’d try the mount / umount method of attaching them (the later is what OS X does)
I’ll be doing some investigation. I also have this to go on.
This: sudo mount -t smbfs //downtown/Users /mnt/downtown -o username=username,password=password ought to work, but doesn’t. Here is what the system log has to say:
[1324145.366237] eth1: New link status: AP In Range (0005)
[1324457.264963] eth1: New link status: AP Out of Range (0004)
[1324457.359436] eth1: New link status: AP In Range (0005)
[1324552.947574] eth1: New link status: AP Out of Range (0004)
[1324553.665238] eth1: New link status: AP In Range (0005)
[1324613.083440] eth1: New link status: AP Out of Range (0004)
[1324613.168185] eth1: New link status: AP In Range (0005)
[1324876.140151] eth1: New link status: AP Out of Range (0004)
[1324876.230793] eth1: New link status: AP In Range (0005)
[1324914.600323] smbfs: mount_data version 1970496882 is not supported
I know it is off topic, but what is up with the link status bouncing in and out of range like that?
PS. I am really sorry if I somehow gave you the impression that my blog is interesting to anyone but me.
command-line, learning
In learning, linux on November 2, 2005 at 10:34 am
Tags: learning, command line
This happens a fair amount, in different ways: a text file, when I open it with vim in a shell account, has no line breaks — they are all ^M. This file used to be readable, even in Vim. I don’t know if someone else edited it or what. I don’t know who to blame, or how to keep it from happening again. One way to find out whether someone edited it would be to look in the CVS comment history for the file, but I don’t know how to do that, either.
- What does ^M mean?
it is ASCII character 13, aka CR or ^M–the Mac OS carraige return character. Unix and Linux software tend to favor the line feed charcter, ASCII 10, aka LF or ^J. DOS based stuff (eg Windows) use both, carraige return plus line feed \n\r aka just to be tricky.
- How can I eradicate it with a search? The string is a single character, I ought to be able to replace it with line breaks, but I don’t know how to type it.
CTRL-m is theoretically how you type ^M, so you can actually drop it into a search and replace statement, but in order to get it to work (and not just execute CTRL-m) I had to type CTRL-vCTRL-m. Try it out. This command :%s/CTRL-v CTRL-m//g worked for me in vim, on a file with good linebreaks AND loose ^M characters at the end of each line. The CTRL-v part is terminal specific, so you might find that you have to fuss to get the right combo for your OS, terminal and shell.
- How did it get there? Did I (or someone else?) edit the file and inadvertently change the line break formatting?
That, I still don’t quite know. Coulda been a lot of ways.
- And then, how can I see a history of comments or figure out when this ^M thing was introduced? I don’t see anything obvious in the CVS Man pages for History.
That would be because history is the wrong command. Try cvs log index.php to see the list of comments and cvs diff -u -r 1.3 -r 1.4 index.php to diff to recent revisions (in this case 1.3 and 1.4).
How do I solve this problem?
These commands are important but they don’t actually work in every case:
:set ff? will tell you what vim thinks the file format is. You can change it with these:
:set fileformat=unix
:set fileformat=dos
:set fileformat=mac
You can search and replace within vim:
:%s/CTRL-vCTRL-m/CTRL-vCTRL-m/g which will come out looking like :%s/^M/^M/g as you type it. It seems a little backasswards that this would work, but it happens to. If that offends you …
You can use the “translate” command, tr, which can do character substitution from outside of vim:
tr '\r' '\n' <macfile.txt >unixfile.txt which will replace mac CR characters in macfile.txt with LF and save it as unixfile.txt
tr '\r' '\n' <macfile.txt | grep word which will allow you to search the file for lines containing word– grep doesn’t recognize CR line breaks so it thinks the whole file is one line, which doesn’t yield very helpful line breaks. This one won’t change the macfile.txt, but grep will search the output.
Or a perl script:
perl -p -e 's/\r/\n/g' macfile.txt >unixfile.txt which will convert macfile.txt to unix format, and save the result as unixfile.txt. This is functionally identical to the first example, but since perl is actually a very general programming language, it can also do some other useful things… BTW, he -e means the program will be the next thing on the command line (‘s/\r/\n/g’ – perlese for replace all \r’s with \n’s), and the -p means do this for each line of the file.
perl -pi -e 's/\r/\n/g' textfile.txt will convert the file textfile.txt from Mac-style (CR) line breaks to unix-style (LF), and replace the original file with the converted version (that’s what the -i means).
perl -pi -e 's/\r\n?/\n/g' textfile.txt convert the file textfile.txt from Mac-style (CR) or PC-style (CRLF) line breaks to unix-style (LF), and replace the original file.
perl -pi -e 's/\r\n?/\n/g' *.txt convert all text files (or rather, files with .txt extensions) in the current directory to unix-style breaks. Note that any that were already in unix format will not be changed.
perl -pi -e 's/\n/\r/g' textfile.txt convert the file textfile.txt from unix-style (LF) line breaks to Mac-style (CR), and replace the original file.
I think you can do much of the same with sed, but I don’t know sed so well.
Gratitude: these guys helped me figure out how to say this all coherently. As did the Vim tipsheets on sourceforge
learning, linux, technology, ubuntu, whining
In learning, linux, various on October 21, 2005 at 2:43 pm
Tags: linux, ubuntu, technology, whining
I installed Ubuntu on my (a) PowerBook g4, for all the wrong reasons (neooffice is so slow on OSX, Linux is kewl) and I am trying to adapt, but I have hit the following walls:
* IMAP: I finally decided to go the IMAP route since I am forever failing at syncing my various laptops and checking email efficiently. I set up some folders and things are going fine, but I am confused: if I create filters locally, on one computer and/or move files into folders, will that stick on the server? Also, if I make a folder locally, will THAT stick on the server?
* Plain Text: How the heck to I make the text formatting disappear in the Thunderbird compose view? Grrr. Also, how do I force everything to plain text, coming and going? I know I worked this out on my Mac, but I don’t remember how. I think it was tricky.
Thunderbird is also ignoring my quote messages inline settings for the account in the Local Folders, which peeves me.
http://kb.mozillazine.org/Plain_text_e-mail_%28Thunderbird%29
Never give up: the Thunderbird Knowledge Base set me on the path to the answer for this one, It is a combination of edit > preferences and edit > account settings ... that you are looking for here. Settings are sprinkled all over but it is at least possible to turn off all inline quoting and RTF emailing and force all messages, incoming and outgoing, into Unicode. Whew.
* Threading how do I get a “threading” button to appear on my toolbar? How do I make Thunderbird always thread all folders by default?
* Key Mapping: I don’t have an “alt” key, I only have one control key and suddenly my fabulous open apple keys are moot. To right click without an external mouse I have to mouse over and press f12 which is just weird. I want to do some basic keymapping along the lines of “the open apple is the control key” not map this function and map that function.
* Repositories: I don’t have a command line mysql client, and there isn’t anything listed under Add Programs that fits the bill. I don’t really know how to look at that gui interface and understand how to edit my repository list and I don’t know how find that in a text file, though I know it is there to be found.
* Music: I can’t get Rythmbox to play music off of the network. My music is on the network, is that so hard?
* Saving Files did I already gripe about not being able to navigate to an smb share in the open office save dialog?
audio, learning, technology
In learning, various on October 20, 2005 at 3:05 pm
Tags: audio, technology, learning
Truth is, I have been trying to figure out how to edit audio on my computer for five years. Maybe more. First I got a cd burner, figuring I’d need a place to store large digital files. I got a discman. I got SoundForge, but it turned out that I didn’t have the right sound card. I don’t understand about sound cards, but it wasn’t going to work. I even interned at a radio station and learned how to edit analog audio, mark with chalk, slice with razor, tape together, transfer to cart. But I can’t figure out how to do it without a whole radio station at my disposal. I’ve drifted since then, but I keep coming back to this project and I want to make it work. I really do.
But I don’t get it, I don’t understand. There are terms that mean nothing to me, and these terms, they seem to be core to my being able to do this.
I have a sony mini disc walkman with a line out. I have recordings of different things and a general idea of how I want to edit and arrange them.
I want the audio on a computer. I also have a tape deck and record player that I want to use to create digital content, but that is a later issue. Except that it isn’t.
Also, I have a little bitty mic thing that I got at radio shack because I couldn’t find the mic that Lex loaned me. I am not sure whether it is capturing very quality sound.
I have the following computers at my disposal:
* a powerbook g4 with osx 10.3 and garage band (gregory suggested this might work)
* an unreliable xp dell that has audiology on it (unreliable in that Dell support has confirmed that it has a bad motherboard and that is why it can’t be counted on to turn on when you go to turn it on. for now, we just don’t turn it off. i don’t want to get too attached)
* a powerbook g4 with ubuntu — my fantasy was that I could use this machine but after spending about five minutes on the skype forums I have established that skype doesn’t make a build for PPC, I am suddenly wondering whether architecture is going to be an issue
I have no external sound card, nor do I have a way to import audio (I spent some time on the mac today, trying to figure out where to plug the line out into, couldn’t get garage band to hear the audio).
I think that I need these things:
* a better external sound card — the apodio guys seemed to think that I could get “a decent” sound card for < $100, but I have no idea what a decent sound card is. How do I know?
* a better mic — this can wait, or maybe I’ll pick Tianna’s brain about this at some point. I want a better mic for future projects. First I want to get what I have onto the computer.
* software to import audio — what do you use?
* software to edit and manipulate audio — what do you like and use?
I am hoping that you kids can help orientate me. I don’t want to buy anything that will be Mac specific, because I don’t plan to have the mac forever. I know that a few of you have pro tools, I am hoping that you can at least suggest something else.