Feeds:
Posts
Comments

Archive for the ‘Miscillaneous’ Category

I figured I would pass along some info I have collected while playing around over on the free services of Amazon AWS. One of the nifty things about AWS is that they offer a number of ‘free tier‘ services for trying out what they offer as well as getting familiar with the environment.  (Other services can be used with minimal expense for low-level usage – just pennies per month)

On such free tier service is the EC2 virtual server environment, which supports a number of operating systems including Amazon’s linux, Ubuntu, Windows, and other operating systems on a 1Gb memory, 8Gb storage* virtual server. (free services can also add elastic storage to increase the 8Gb if needed)

One problem you’ll run into right away is that 1Gb of memory is a small amount when using some modern tools. No problem, you can create virtual memory with a swap file using some of that free tier storage space. However, the instructions on the AWS documentation pages assumes a system larger than the free tier and won’t work as written.
The first problem will be encountered right off the bat. As with most other static-swapfile implementations, they create a static file using dd in conjunction with /dev/zero to create the initial file. The problem is, their example uses a blocksize equal to (1Gb) the total memory of the EC2 free tier instance. So instead use a smaller blocksize and a bigger count.  I used 128M which uses a count of 8 for 1Gb in size. So for example, to create a 1 1/2 Gb swap file:

$ sudo dd if=/dev/zero of=/swapfile bs=128M count=12

The rest can be done as documented: How do I allocate memory to work as swap space in an Amazon EC2 instance by using a swap file?

Another useful diddy is the ability to mount an S3 bucket as a local fuse device. This is made possible with >s3fs. Follow their instructions then you can even mount the device using an fstab entry. Example:

s3fs#mybucket /media/mybucket fuse _netdev,use_cache=/tmp,allow_other,default_acl=public-read,endpoint=us-east-2,dbglevel=info,uid=33,gid=33,mp_umask=002,multireq_max=5,url=https://s3-us-east-2.amazonaws.com 0 0

Replace ‘mybucket’ with the name of your bucket after the s3fs# and pick your own mount point as the second option. A few notes on some of the other options. You can exclude the default_acl if you want to use the bucket default. In this case I use ‘public-read’ to mark any newly created files as publicly readable. The combination of the endpoint and the url options makes sure you are accessing a region-specific bucket without error. uid and gid can be set to whatever user you wish. (in this case I am setting both to www-data). mp_umask is a reverse mask of the file permissions when mounted. You can also vary the debugging level as needed when troubleshooting. (be sure to read the instructions on setting up the /etc/passwd-s3fs file)

One thing to note is that you will need to assign permissions (likely an IAM role) to your EC2 instance that has access to S3 or at least your S3 bucket depending on what specific functions you want to do over the virtual-fuse connection. (e.g. give S3 createObject/delObject permissions if you want write access, getObject to read, etc – one easy way to do this at first is to add the S3FullAccess policy until you learn specifically what you need)

If you plan on playing with lambda, especially with custom runtime environments, the EC2 free tier is also useful as you can create an Amazon linux instance to compile the runtime environments to work on lambda. (NOTE: lambda uses the original version of Amazon linux, not Amazon linux 2. You’ll get GLIBC errors if you don’t downgrade the gcc environment on other platforms to match the libraries used on the original amazon linux)

It should be noted that the free tier servers on EC2 give you 32 days per month total. So this is more than enough to run a single free-tier-eligible instance non-stop all month, or to run multiple instances intermittently in so long as the combined usage does not exceed 32 hours. For example, I run an Ubuntu non-stop, but have an amazon linux instance for creating the runtime configurations that I only power up when needed. That gives me 24-48 hours of usage per month on the second instance without exceeding the total usage. (bonus time in February!)

Read Full Post »

The claim of global warming/climate change is not as simple as ‘it is happening’. The assertion involves over 8 different premises, and none of them (beyond the first) are proven conclusively while many of them aren’t even addressed or acknowledged by anyone claiming to be pro-change. Furthermore, each subsequent claim relies on ALL* of the prior ones already having been proven to even be relevant.
*(at least one variant of in regard to #6)

1) the climate is changing (This is a given. The climate changes all the time. This is not a cause to action. Getting worked up because the climate changes is like getting worked up because the sun sets every evening or because the sky may cloud over occasionally. The only reason it is included in this list at all is because this is the primary reason being given by those suggesting such political and social changes.)

2a) the change is atypical (i.e. not part of a short term trend or long-term cycle, effects of the sun, etc.)
&
2b) the change is on-going and not simply local/transient in nature

3) The earth (which has survived on it’s own for 4 billion years, a living biome for at least 3.5 billion of that time) will not or will not fully compensate, repair or re-adjust for anything ongoing or unnatural on it’s own

4) the effects of said change are going to be predominantly bad (and/or will not include positive effects)

5) human activity is a primary cause

6a) ceasing or changing said activity will reverse said cause and/or minimize the predominantly bad effects in #4
…. or (if 5 is all or part bullshit)
6b) There is something/anything humanity can do about it (whether we are a cause, an active contributor, a passive contributor or have nothing to do with it what-so-ever)

7) those telling us what to cease or change in regard to our behavior are [the most] correct in knowing what to cease or change

8) the things we are told to change or alter will not ultimately make things worse in the long run

NASA-Carbon-Dioxide-2

Read Full Post »

I was having a little fun on facebook last night, pondering what I would do if I ever have to set up password protected systems at work, that I would have a little fun with the passwords and names I pick…..


abbot-costello
co-worker: Hey, how do I get into that file share you set up?
me: Just type in the password.
cw: ok, what’s the password?
me: “I dunno”
cw: Huh? Then how do you get into it?
me: what do you mean?
cw: when you need to get into the share you set up, how do you connect to it?
me: I type in the password.
cw: but you just said you don’t know the password.
me: No, you asked me what the password was, and I told you… “I dunno”!

*long sigh*
cw: ok, ok – is there any other way I can access the files?
me: Sure, I threw them on a memory stick.
*hands over USB drive*
me: it’s in an encrypted file container. You just need to stick it in your computer and type in the pass phrase.
cw: Passphrase?
me: yeah, it’s like a password, but it’s a whole sentence complete with spaces. It’s more secure that way.
cw: Oh ok. That makes sense. So what is the pass phrase?
me: “I don’t know what the passphrase is”
cw: what? Then why in the hell did you give me the memory stick?
me: what do you mean? You asked me if there was another way to access the files, so I gave it to you.
cw: Yeah, and you said it needs a passphrase.
me: Yes, just type it in.
cw: Well, ok – then what is it?
me: “I don’t know what the passphrase is”

me: Look… It’s easy, just look for the file on the memory stick.
cw: and the filename for it is?
me: “what”
cw: The file container
me: yes
cw: What is the file container’s name?
me: correct.
cw: The file container is called correct?
me. No, it’s called “what”
cw: I dunno!
me: No that’s the password.
cw: What password?
me: No, “what” has a passphrase…..

cw: So how do I know if I have the right memory stick. Did you give it a label?
me: Yes, “ItsOnTheStick”
cw: What is on the stick?
me: Yes, it is.
cw: so what is the label?
me: no, “what” is the file container.
cw: I dunno
me: That’s the password.
cw: What password?
me: “what” has a passphrase.
cw: I don’t know what the passphrase is.
me: yes, exactly.

cw: *AAAAHHHHGGR* Alright, already. I’ll try to figure it out myself on the network. How do I find the share?
me: Just type in it’s netbios id after two slashes
cw: ok, and that is?
me: “TheName”
cw: yes
me: of course
cw: huh?
me: just type in ‘\\’ then ‘TheName’
cw: and what is the name?
me: No, what is the filecontainer
cw: I dunno!!
me: No that’s the password.
*coworker just shakes head and stares up at the ceiling*

me: I’ll tell you what, I’ll make it easier. I wrote up a wiki page. Just go onto the wiki and look for the words “if you want to access the file share”
cw: OK, and the words I’m looking for are what?
me: No what is on the memory stick!
cw: FORGET ABOUT THE MEMORY STICK FOR A SECOND. I go onto the wiki and search for the words….. *spreads out hands expectantly*
me: “If you want to access the file share”
cw: yes!!!!
me: well there you go!
cw: There I go what??????
me: *points at the USB stick again*

Read Full Post »

It was an old fashioned frame building, this headquarters of the great Danagger Coal Company. Somewhere in the hills beyond the window were the pits where Ken Danagger had once worked as a miner. He had never moved his office away from the coal fields.

When she glanced at the clock on the wall of the anteroom, she caught the secretary glancing at it at the same time. Her appointment was for three o’clock; the white dial said 3:03.

“Please forgive it, Miss Taggart,” said the secretary, Mr. Danagger will be through any moment now. Please believe me, this is unprecedented.”

When she raised her head to glance at the clock again, the dial said 3:06. Dagny looked at the closed door of Danagger’s office. She could hear the sound of a voice beyond the door, but so faintly that she could not tell whether it was the voice of one man or the conversation of two.

“How long has Mr. Danagger been in conference?” she asked.

“Since a few minutes before three,” said the secretary grimly. “It was an unscheduled caller.”

The door was not locked, thought Dagney; she felt an unreasoning desire to tear it open and walk in. She realized that she was thinking of Hugh Akston. She had emailed him at his diner in Wyoming. The email had bounced back from a new spam filter. She told herself angrily that this had no connection with the present moment and that she had to control her nerves.

Dagny asked the secretary slowly, as a demand, in defiance of office etiquette, “Who is with Mr. Danagger?”

“I don’t know, Miss Taggart. I’ve never seen the gentleman before.”

“Did he give his name?”

“No.”

“What does he look like?”

“I don’t know,” she answered uneasily. “He’s hard to describe. He has a strange face.”

They had been silent for a short while, and the hands of the dial were approaching 3:08 when the buzzer rang on the secretary’s desk — the bell from Danagger’s office, the signal of permission to enter.

They both leaped to their feet, and the secretary rushed forward, smiling with relief, hastening to open the door.

As she entered Danagger’s office, Dagny saw the back exit door closing after the caller who had preceded her. She heard the knock of the door against the jamb and the faint tinkle of the glass panel.

Ken Dannager (from Atlas Shrugged part II)

He did not rise when she entered — he looked as if he had not quite shaken off the reality of the prior caller and had forgotten the proper routine — but he smiled at her with such a sarcastic twist that she found herself smiling in answer.

“How do you do, Miss Taggart,” he said. “Forgive me, I think that I have kept you waiting. Please sit down.”

“I didn’t mind waiting,” she said. “I was exremely anxious to speak to you on a matter of urgent importance. I came to speak to you about your indictment.”

“Oh, that? Don’t worry about that. It doesn’t matter. I’m going to pay off the judge by making a big donation to one of his favorite ‘charities’.”

She sat still, feeling nothing. Her first movement was a sudden jerk of her head toward the exit door; she asked, her voice low, “Who was he?”

Danagger laughed. “I have no idea! Some sales guy I assume. He was apparently talking about some property he wanted me to invest in — Galt’s Gulch, can you believe that? Trying to cash in on that whole ‘Who is…’ meme? He had some kind of rationalistic morals appeal and said it was some kind of perfect Nirvana!”

“Oh God, Danagger!” she moaned.

“You’re wrong, kid,” he said gently. “I know how you feel, but you’re wrong. Oh, it sounded great — like most of those guys sound — but I told him it wasn’t ‘practical’. I have my business here and I’ve spent years building it up, I can’t retire now! I’ve almost paid off my condo and I want to buy that new boat next spring. And I have to think about my kids! I have to get them into the right schools after all!” And at that he laughed.

Dagny nodded.

“I wonder if he was the same guy Wyatt told me about. Some guy hit him up too, trying to get him to burn his oil fields and go to some remote place in Colorado for goodness sake! Wyatt said with his new fracking method he can pull out enough oil in North Dakota to make this entire country energy independent in just over 5 years — well that is if he can get that pipeline built and get the permission to drill in that national park where he says the big deposit is located. And of course, he’s dealing with all the red tape from the EPA and the BLM.  They’re giving him some song and dance about a rare field mouse in the area. But I’m sure they’ll come around, right?”

Danagger just shrugged.

“OH, can you do me a favor. If you’re heading back to your office in the next few days, can you drop this check off in Washington?”

She picked up the check and could see the 5 zeros on the sum next to the words ‘Republican National Committee’.

“What is this?” she asked.

“Oh, just a donation to someone’s favorite ‘charity’ — I want to make sure they get it in time to make good use of it for Christie’s 2016 run against Hillary….

Read Full Post »

ImageI’ll never forget when US Airways flight 1549 had to do an emergency belly landing in the Hudson river and no one was injured. Shortly following the event, a whole lot of people started clamoring about how it was ‘a miracle’ or that God definitely played a role in getting all those people to safety. My inbox was no exception.

Such things tend to frustrate me because it shows the blatant confirmation bias of the religious thinker. No one questions that ‘God’ steps in to do the ‘good’ outcome but they do not also apply that similar thinking to the ‘bad’ outcomes any more than they think the same ‘God’ would have played a role in causing or should have played a role in preventing the situation in the first place.

For example, do you suppose that anyone on board was ‘cursing’ God when they thought they were going to die? Or what about passengers or witnesses to crashes where no one survives? Well, obviously, that is just part of God’s plan then right? It’s a mystery!

Such thinking is not only inconsistent and intellectually dishonest, it distracts from the real heroes doing real things — real people! — who are contributing to great outcomes. To more than one person who sent me the ‘miraculous’ assertion, I had but one response:

Yes, I am sure that God personally intervened to make sure that all of those passengers and crew as well as the people on the ground were not harmed.
I’m sure that the years of training and calm headed, quick thinking of the pilot and the flight crew played absolutely no role in keeping the jet from crashing.
And the air traffic controllers using the world’s most advanced and coordinated air traffic system, radar technology, two-way radio communications and direct lines to multiple airports across the northeast didn’t have anything to do with it.
Nor did the years of development and advancement in aircraft design, technology and safety measures contribute in any fashion.
The flight attendants, their years of training and their similar cool thinking keeping the passengers calm and following safety procedures that have been practiced and rehearsed had nothing to do with it.
Not to mention the passengers themselves for following instructions and remaining so calm and working together.
No one on the ground in New York city with a cell phone, similarly developed through years of technology utilizing one of the most advanced telephone systems in the world calling upon seeing the plane going down did anything to help.
The 911 operators utilizing their refined network of emergency resources and vast network of trained emergency response procedures obviously did not contribute.
Nor did the quick response of the harbor authority and their rescue vehicles that rushed to the aid of the plane once it was safely upon the water.
Obviously it was all God’s work.

Now I’m sure you’ll probably say ‘well, God created all those things’ or that he had a hand in carrying them out. But I’m just curious. If God really wanted to make sure all of those people were safe, wouldn’t it have been far easier and less trouble in the long run….

…. if he had just moved the goose 3′ to the left?”

WSIDAirplaneGeeseinFlight

Read Full Post »

I often get question on my methods and intentions as to how I tend to take an ‘in-your-face’ approach to addressing absurdities and things that I view as bad behavior. When describing such things, I am quick to point out that I do such things ‘when appropropriate’. What this means is not only do I judge whether a situation is worth (deserves) speaking out about, but whether it can be done in a manner that will not bring harm unto myself. (see my blog post on the Golden Rule) When pressed for an example of what I’m talking about, there is one particular story that always pops into my head.

When I was still living with my folks and going to college, I did a greater deal of my hunting at a small plot of old Dodge family donated land in NE Oakland county called simply “Dodge Park #10” up off of Oakwood Road north of Oxford, MI. As it was not an official ‘park’ (with any facilities or a day use area) the bulk of the people using it were hunters in the fall. However, in that it was rather remote down the dirt portion of Oakwood road surrounded by undeveloped land on the north and a large aggregate gravel pit on the south, it was often a hangout for local high school kids outside of the hunting season.
One particular year, the state Department of Natural Resources was having trouble with kids ‘baha-ing’ off of the state access service road behind the main parking area. Initially they had up a rather basic locked swing gate. The kids broke off the lock. Then they bolted the gate shut. The kids unbolted it. Finally they brought in a whole dump-truck full of dirt and broken up concrete, put it across the entire service road making it inaccessible even to themselves and again put up the bolted gate.

oakwoodOne particular fall during bow season, I show up at the main parking lot to find 3 cars of hunters – all standing around gawking, and a jeep full of high school kids in various states of industry. By the time I showed up, the kids had already unbolted the gate again and they were in the process (about 8 of them) of removing the concrete blocks one by one. I surveyed the scene and most of the hunters were looking at one another and shrugging. Reluctant to leave thinking they should do something, but the looks on their faces amounting to “what can we do?”
I wasted no time and quickly went about donning my hunting gear and feigning to be oblivious to what was going on as I listened to the conversations on both sides. The kids were content in ignoring the other hunters and myself, realizing they felt they could do nothing about it and taking advantage of that fact. The hunters kept making comments to one another quiet enough not to be heard by the kids along the lines of ‘what gall’ and again, ‘well, what can you do?’ (mind you, this was before wide scale use of personal cell phones)

I eventually finished getting my gear on, threw my bow over my shoulder and took one last look at the hunters with an attempt to put a very obvious ‘disappointed’ look on my face communicating ‘how pathetic you are!’ I locked up the back of the truck, went to the front and reached into the console where I always kept a pad of paper and a pen for just such events. (I should also point out that when I came into the parking lot, I backed into my space so my truck would be facing forward)
I then took the pen and pad and walked so as to be as obvious as possible up behind the jeep and scribbled something down. A couple of the kids looked up at me as I did this and I just gave them a wave and a sarcastic smile, walked back over to my truck, put the pen back in the visor and threw the still-open pad of paper onto the dashboard where it would be well within view of anyone that wandered over to look. I then re-situated my bow on my shoulder, tipped my camo wool stetson at the hunters with a look of ‘was that hard?’ then gave another sarcastic smile to one of the kids still watching me, tipping my hat again and proceeded to walk into the woods.

Knowing that there was going to be quite a spectacle going on behind me and guessing that no one would make a move until I was well out of sight, I headed for a thick spot in the brush, walked into it and proceeded to do a ‘j-hook’ so I could watch what resulted. Since I was in full camo and tend to be quite stealthy in the woods, I was quite certain no one saw me pull off this maneuver and since it was a thick stand of alders, I was also confident no one saw me looking on.

First one of the hunters came over and looked at the slip and threw his hands up turning to his buddies and laughing. “why didn’t I think of that?” he said – or something of the sort. Most of the kids had gone back to working on removing the blocks except for the main two who watched me writing. The one that continued to watch me then walked over to take a look at the slip himself.It was obvious he had a good idea what was on the slip already, but he then quickly went over to grab one of the larger boys (probably either the one who was driving or the one who had the bright idea to go out baha’ing that particular afternoon). They both walked over and looked at the slip again as the hunters started to laugh and grab there own things finally assuming the most likely result.
The two boys talked to one another briefly, took a look around to see if they could spot where I went but I was well out of sight, paused briefly, looked back at my truck, looked at the other hunters watching them intently then finally shrugged and told their friends to pack it in. They all loaded into the jeep and left and I never saw the jeep or the kids there again – and the bricks remained until I stopped hunting there years later.

What did I right down? Well in case you hadn’t figured it out all ready, just a couple of letters and numbers. I simply wrote down their license plate and a short description of the jeep.

The point being, that as long as the kids felt no one could – and no one would – do anything to stop them, they felt emboldened to do whatever they pleased. As long as it was obvious that the hunters were just going to stand there and do nothing, there was no problem with doing something that was obviously wrong. It wasn’t until someone ‘stood up’ and did ‘something’ that said – “no, not gonna happen – not on my watch – not without appropriate consequences” that they decided to give up their venture.

licenseI didn’t make a huge scene. I didn’t get in any arguments. I didn’t tell them what to do or what not to do. I simply made it clear that they were being watched, and that I had taken note of who they were and what they were doing with one simple gesture.

As an aside, I had already used this practice – most specifically against other hunters who were behaving badly. (it’s a subject for another blog, but I am far harder on other hunters behaving badly then I would ever be to ‘day users’ because, in a manner of speaking, those hunters represent me) In those cases, such as when hunters are shooting at anything that moves or at road signs, dumping trash, drinking beer, etc. I wait for said hunters to be well back in the woods and simply write down their license plate number and stick it – by itself – under their own windshield wiper. There’s nothing funnier but to watch than one of them coming back to the car and going through the chain of thought necessary to realize that if someone had the where-with-all to write it down once, that they could write it down twice – then to think back through their own mind to what they might have done to inspire it. It requires them to come to their own conclusions as to what they may have been doing to ‘inspire’ such a gesture, then make their own choice how to proceed.

Apathy sux! Pass it along…

Read Full Post »

lightbulb-idea

A few absolutes about human ideas…

  1. If you can conceive of it, chances are someone has already thought of it before.
  2. If you try to do anything about it, someone will claim they thought of it first (whether they did or not) and try to stop you.
  3. If you try to build it, some union boss is going to say you need to do it with union labor.
  4. If you actually build it, some advocacy group is going to claim it is dangerous to the environment, harmful to children, unfair to minorities, etc.
  5. If it turns out to be beneficial, some religious group will say it’s a miracle and try to give the credit to their chosen god or gods.
  6. If it is cutting-edge, some other group is going to say it’s evil and try to get it banned, protest your workshop or declare a holy/social war against you.
  7. If it is useful, someone in the military is going to try to find a way to weaponize it.
  8. If you created it for a specific purpose, someone will eventually find a way to misuse it regardless of how many warning labels you put upon it. (See #7 & #12)
  9. If it can be used in any way to hurt somebody else (see #4, #7 and possibly #12) then someone will use it that way on others despite the labels and warnings in #8.  Refer back to #6 for the consequences.
  10. If you try to sell it, someone in China will quickly make a knock-off version of it for less.
  11. If it makes money, someone in government is going to find a way to tax it. If it makes people’s lives simpler and easier, someone in government will require 14 forms to get one and further regulate it to make it more difficult and complicated.
  12. If people buy it, someone will eventually find a sexual use for it.
  13. If you make it durable, someone will find a way to break it.
  14. If it makes you rich, some liberal is going to say you exploited your customers, workers or the environment getting that way.

Read Full Post »

Older Posts »