Load CSV file into MySQL (specific columns)

load data local infile 'zipcodes.csv' into table zip_codes fields terminated by ','
enclosed by '"'
lines terminated by '\n'
(zip, city, state)

Above commands will load column 1,2,3 of the zip file into zip, city, state fields of the table correspondingly.

Thanks to:

http://www.tech-recipes.com/rx/2345/import_csv_file_directly_into_mysql/

http://www.mysqltutorial.org/import-csv-file-mysql-table/

http://stackoverflow.com/questions/3635166/how-to-import-csv-file-to-mysql-table

Halfway Jaded

Not too many people will read this post and that is the way I want it,  it’s the type of stuff, in all irony,  that just can’t last – it’s a little too close to the truth.  I’m jaded, with so much still to learn.  I’m only 27, still young, and I’ve learned a little about making a buck, really nothing too serious, but something none the less.  If I had to sum it up, it’s really not all that hard – It’s all just bull shit, every last dime.  Nothing about hard work, honesty, innovation, integrity will make penny, it’s conniving, cunning,  publicity, efficiency, duplicity and monopoly that does the trick – every singly fucking time.

You see, I just pulled through a Bojangle’s, picked up my food from a $7.25, hurried, sincere,  friendly,  mid-30s black lady. I pull $50/hr – from my day job + my side scams that make that (in a bad hour), and I’m small fries – like you would not believe.  Day in and day out, she rises early, kneels, prays,  does her devotions, suits up, drops the kids off at school with a kiss, stiffens and goes to work – $7.25/hour. The budget, for her, is more than tight, the math just does not  add up, but she maintains – trudges on.

That’s one way to go, but if you wan’t to not get FUCKED,  you’ve got to get jaded.  You see, it’s all about the cash, everything you read, everything you see, everything you think, it’s all built to keep the cash machine cranking, once it’s up and running – it can’t be stopped. It’s the noticing of Democracy vs Kratocracy. Make your best friends: doubt, skepticism,  pessimism and grey, then you’ll have a much better chance of survival.

And here I must admit, despite my brief shock and disgust, shit, I love it. It’s vile and quick, brutal and just, more than just rough,  fuck, it’s born in upon me, I love it – the demand for survival of only the tough.

 

When The Top Falls Out

I almost wish that four walls were around me, containing, it’s the desire to fall somewhere on the hierarchy. It’s the romance of sliding your hand along the unbreakable bubble in the hope of a collision with another, petite, far less rough hand. When the walls fall down, and your completely free, well that’s it, the tension is all gone – and you see it’s the tension that you wanted all along.

The foundation you all have got, has washed away in me, with it comes a great deal of beauty, but on the losses. It was a single file line, that you just might skip; but now it’s a contraption, to be triggered without a glitch. A piece falls, and hits the next, rolls a ball that barely tings a board that spins the…. I think you get the rest. I’m grown up, it’s not that, still most old folks won’t have a clue what I’m talking about.  It’s when there is no top, and now you can see, how the entire machine will crank, when words are spoken, and you already know exactly what they will be.  Yes, I am free, but it’s at the cost of a state ,that one in love,  should never have to know.

So, what the fuck am I  talking about. It’s something to do with love, flourishing only in the midst of oppression.  When it’s allowed, freed, compliant – is exactly when it deteriorates into the cold steady march of reality.

 

On the supernatural

It was Freud who sparked the idea that religion and the afterlife it offers was primarily a way one could cope with their impending death, I hear this explanation often and find it lacking at best.  Do people really sit around thinking about death that much? The thought does not pop into my mind all that much, and when it does, nothingness is not all that scary. I would guess most folks, especially younger folks, don’t believe in a particular religion or afterlife it offers because of some unbearable fear of death – at least not as the primary reason for belief.

The culprit of religious belief is, I would guess, far more complex and is in a much larger part explained by the idea of the supernatural.  It’s ironic how the religious are often accused of closed-mindedness  -  the case  is exactly the opposite. It takes a beautifully creative, uniquely human, well adjusted and open mind in order to fashion such a realm. The trouble is, once fashioned – the game is over. Anything and everything now enters into the range of probabilities, we have not data, no patterns to work from in order to know what is likely or unlikely to occur in this realm  -  it becomes just a question of what idea’s get there first, here the mind is open to anything.

This partitioning of the brain does seem to come naturally – I notice it too, but can it be trusted? My accusation is that the supernatural exists only in one’s mind – and can be found nowhere outside of the mind. Consider for a moment the supernatural, it does seem highly probable that there are other realms of existence going unnoticed by us, perhaps right on top of us, beside us, intertwined with us. It would be naive to assume that we are in the one and only plan of existence.The trouble with this thinking is the smudging of the un-observable and the supernatural.  Prior to the microscope we were unable to access an entire realm of the molecular,  prior to the telescope we could not access the astronomical –  two beautiful realms with vastly differing governing laws, both we knew nothing about. Who would suggest that the molecular or astronomical realms are not part of nature? No, they were merely unobservable to us. I would suggest that if something exists, we can not rule out the possibility of our ability to access it’s realm through scientific means. It’s at this point where one’s idea of the supernatural rebels , no this can’t be accessed by scientific means, its off limits by its nature to scientific inquire – it can’t be accessed that way, it must be accessed by some other method. It is by the maintaining  of this requirement that we can know the supernatural exists, and that we can be certain it’s existence is limited purely to the mind.

 

A disconcerting catch 22

I have always thought philosophy to be a terrible waste of time, that is, if one cares to actually change anything – if the goal is to sulk or gain esteem then it’s the proper business.   With those goals in mind, I was thinking about the anthropic principle  - more specifically it’s blatant problems, it’s fallacy.  I wonder, if that fallacy, when applied to other domains could give us some (useless) insight we could not otherwise know. My thinking  goes like this – the problem with being shocked with all the “constants” in the universe that are calibrated specifically for us, is that they are in fact, necessarily in order us to be here. It would be fair to be shocked by them if we knew the bounds of the universe then we could do some quick math to see if random chance could get us here, or if it would require something else to be at work.  Since we don’t know the bounds of the universe, we should not be particularly surprised at what must be necessarily true – in other words, what are the chances that you are the lucky sperm out of your 250 billion competitors?

This got me thinking, if constants like gravity must be what they are in order for us to be here, what else must be necessary.  Thinking in the context of evolution, I have often wondered why we humans are the first to evolve to be so clever, seems like a HUGE evolutionary advantage that should happen over and over among various species. Out of the guesstimated 9 million species that have existed we are the first (on earth at least) to be lucky enough to evolve such a high level of intelligence,  it’s not necessary that we have to be the FIRST to have evolved these big brains – we could have found civilizations of dinosaurs who could read, write, set up shop and so on. It would appear that its just good luck that we are the first clever mammals – unless it’s not luck. A solemn thought. What if we are the first on this earth, because it is indeed necessary true, because it’s our cleverness that requires that we be the last – the final species.

This would leave us in uniquely ironic spot, given only this argument as proof of the earth impeding annihilation – there is by definition of the argument, nothing we could do to change the circumstances.  This, therefore proves my point to begin with – philosophical arguments are utterly useless in solving real problems, but do the job of feeding ones hubris and pessimism damn well.

If you haven’t caught the glaring necessity required in the making of this “why are we the FIRST clever species” argument –  think on it briefly and you will.  I do see the problem, but somehow it’s recognition does not make me feel any better. 

 

 

Consciousness and Computers

A few whiskeys in on a wednesday night –  pretty standard, but unfortunately I now got the itch to hit the keyboard alongside the sauce.

There has been a decent amount of (far too much) talk on consciousness, it’s nature, how mysterious it is and what not.  I often hear “intellects” say that soon computers will be conscious, Lawrence Krauss & Sam Harris both seem quite confident that this achievement is just around the corner. The thrust of the idea is that if computers were able to perfectly clone the human mind then voila - consciousness.

From my  seat, this assertion fails on two fronts – first the good news.  Just practically speaking, computers are not close in architecture to the human mind, and they don’t appear to be getting closer – this is not to mention the massive gap in complexity of the two domains.  Suggesting a computer could work like the human mind, is next to suggesting we could setup shovels in a dominos like fashion that would somehow function as a brain. We are neither using the proper tools, know the appropriate ingredients,  or are generally heading in right the direction. As a good old fashion pessimist, I feel fine saying that one can be confident that we wipe ourselves out, or the job will be done for us, far before we can build anything that works like a human brain.

At this point, I imagine the pious & faithful are cheering me on – so, onto the bad news. It’s not that a computer that functions exactly as a human brain can not exist, simply that we will not get there.  And worse  - the hypothetical day that we do “get there” is not the day that computers become consciousness, it’s the day the we realize we are just computers. More bluntly – as we incrementally gain knowledge of each nut/bolt and circuit of the brain, we also gain the knowledge of how this computer will receive, process and respond to input, and finally we know it’s response before it does – bye bye consciousness. One might find knowing we are merely computers a solemn, humbling, grounding experience – I don’t. I find the complexity, the machinery, the naturalistic explanation to make the draw drop just slightly further than any other explanation.

I hope this short (yet still  far to long) post will help those who spend their life studying the “nature of consciousness” (whatever the fuck that means), to STOP,  and  start doing some sort of real science on the brain.

Authors Note: I know nothing about the anatomy of human brain, I do however know a little about computers – this puts me in the very rare position of being able pretend to speak authoritatively about a  topic that any garbage man would be just as qualified to speak on. 

 

Always a Linux box,

- Taylor Hawkes

 

 

 

Sam Harris, Free Will & Strange Thoughts

I just killed a couple hours listening to Sam Harris, Tamler Sommers & David Pizarro arguing about who’s to blame in a drunk driving accident.  Generally Sam Harris seems to have powerful insight, but here he started to flex his buddhist roots pretty hard, his finally tuned “bull shit detector” must have had a big bellied magnet nearby.  Sam finds the idea of freewill to be an illusion, which most “enlightened” folks these day can get on board with, and for now I’ll roll with that idea. I’ll only  pause to point out what we do know; that we all came from nothing,  and if some bro was clever enough it might be possible for him to get right back to nothing, this reverse engineering of reality does not particularly strike me as progress – I’d tend to go the other way.

Anyhow, Sam was really pushing the idea that given that there is no free will,  our complete understanding of one’s actions would prevent us from hating that person for misbehaving.  A prevalent example in the discussion was something like an evil neuroscientist who embedded a program in another humans brain, and was then remotely controlling this person like a puppet, making them do all sorts of bad shit. If the puppet person was to rape your daughter, you may hate that person, however upon gaining knowledge of the puppet/master relation you can no longer hate the puppet, only perhaps the puppeteer.  This extends to the broader idea that given no free will we are not the ultimate authors of our actions.

And here is where the peculiarity in Sam’s thinking gets a massive chub.  He puts forward the idea that we should not really hate the evil doer,  given that when we get a better understanding of the mechanics involved, our hate would dissipate anyway.   When Tamler points out the elephant of a problem with Sam’s thinking; Love – Sam blunderingly says that love is different because we don’t focus on the causes when we love someone, we just like to be around them.  It’s worth pointing out, that by this time in the argument, we have crossed the crust, mantle and are now in the inner core of the purely theoretical realm, a place were arguments are won and lost only by the plasticity of our thought and the extent of our imagination.  But even in the inner core, the thickest of nonsense –  we must have our standards.  If theoretically,  we could strip away all the unknowns of a humans brain, understand every mechanism that is at work in their actions – in other words:  puppet them, rock them,  robot them,  break them down to adams & gravity –  it’s true we may no longer hate the puppet, but it would be quite strange if after applying what few patterns the world has trained us to recognize onto this dissection fairytale, our love for the puppet went unscathed.

I found this worth pointing out, because in order to charge on,  it may be that we all need to take a bite out of some nonsensical idea -  I hoped Sam would be a little harder to take down on this front, not as hungry,  just a little tougher.

 

A devoted puthujjana,

-Taylor Hawkes

 

 

 

 

 

 

Building Asterisk Modules

Compile a module:

gcc -shared res_taysipreload.c -o res_taysipreload.so -fPIC

 

Move to proper dir:

sudo cp res_taysipreload.so /usr/lib/asterisk/modules/

Load: module load res_taysipreload

 

How to set up your own PBX (Phone System)

Setting up an office phone system is not as hard as most people would have you believe.  Thanks to VoIP, technology has gotten to a point where end users can install phones them selves and easily customize the phone system to do what they want.  In about a half an our almost any individual can build their own PBX system, here is a great guide on how to build your own PBX that I wrote recently on RingRoost:  http://www.ringroost.com/how-to-setup-a-pbx.php

So what is a PBX anyway?

A PBX (Private Branch Exchange) is simply a phone system for an office,  a PBX usually has number of phones each assigned an extension.  Each extension can interact with the other extensions in some way (conferencing, call forwarding, queues etc..), and can usually make outbound calls to anywhere in the world.  Traditionally companies would run physical phone lines into their business and install a physical computer on site in order for a PBX to work. Now most PBX system are hosted or virtual. Meaning that the server they run off is not physically located at the business. This means that building your own PBX no longer requires installing your own hardware and software.

 

 

Setting up SSH keys

1. Generate pub/private key one client in ~/.ssh/ : ssh-keygen -t rsa
2. Append public key on client to servers authorized key file: ~/.ssh/authorized_keys
3. On client add private key to keychain: ssh-add -K ~/.ssh/privateKey.txt

note: on ubuntu to add key to  ~/.ssh/config:

<code>IdentityFile ~/.ssh/keyfile.txt</code>
<code> </code>
←Older