Wow. How embarrassing. Stand Your ground laws should only apply to your home. Glad I moved to NY.
Filed under: Brain Droppings, Projects, Tech Articles, Technology, Windows General
They’re everywhere. I hate the logo and everything that goes with it, the cookies, the scripts, the tracking etc etc. It was nice in the beginning but they’re out of control.
What to do….what to do.
Block them and do it creatively. There are LOTS of solutions for blocking them and their scripts and cookies.
My approach is to modify my hosts file and redirect as many of their domains as I can to the trash bin.
GREAT IDEA! But I wanted more. I wanted to be able to track how many times and what pages were getting data/sending data to them. Plus I wanted some simple indication that they had been blocked. Here’s what I did.
I setup a spot on my web server to accept the “redirects”. http://www.jeffw.net/nofb/index.html
If you go there you’ll get a page of little 21×21 pictures of a “No Facebook” icon. Cool!
The 21×21 pixel icon fits neatly where a news page might have a link out to facebook- thus you can see where in the page facebook got blocked.
My web logs also keep track of what pages/URLs were requested so I have some idea of where all these redirects were trying to go.
This is what I added to my hosts file in Windows 7:
184.108.40.206 www.facebook.com facebook.com static.ak.fbcdn.net 220.127.116.11 www.static.ak.fbcdn.net login.facebook.com 18.104.22.168 www.login.facebook.com fbcdn.net www.fbcdn.net 22.214.171.124 fbcdn.com www.fbcdn.com static.ak.connect.facebook.com 126.96.36.199 www.static.ak.connect.facebook.com 188.8.131.52 facebook.net www.facebook.net connect.facebook.net 184.108.40.206 m.facebook.net m.facebook.com
All those domains are now redirected to my server which happily accepts the connection, logs it and gives you a nice big page of “No Facebook” images.
99% of the time you’ll only see a few of the images because that’s all the space a web page will allocate to their “like” section. Good enough. If you see the little image you know it worked.
Now if you don’t want to send your redirects to me so I can collect data about what pages facebook is sending you to, you can easily replace my ip address with 127.0.0.1 which will redirect the links to your local computer. Since you probably don’t have a web server running you’ll get blank spaces instead of my little images.
I’ll update the hosts file entries as I find more that need to be blocked.
Most people have a smart phone, a laptop or desktop and many are getting tablets. Brands, versions, “ecosystems” and connectivity options abound.
Some people choose to stay with one brand for all their devices. Take Apple for example. Apple can supply you with your phone, laptop, desktop and tablet. Going this route gives you incredible consistency in your visual interface and all the devices share data seemlesly. The software ecosystem (App Store) is heavily curated so you generally don’t have to worry about crap software.
Photos, emails, contacts and more are seemless across all of your devices.
Anyone who’s an Apple fan will tell you this is a great experience. Apple succeeded in that area.
Most of us however aren’t 100% Apple. Personally and in my family we’re all over the place.
I have a Windows 7 desktop (home grown), Windows XP laptops (Dell or Acer depending on my mood), Android phone (Samsung Galaxy S3) and an Apple iPad 3.
To the average person sharing data across this mess would be…well…a mess. But it doesn’t have to be.
The common services for all these devices are Google and Dropbox.
Google gives me email, contacts and calendars. Dropbox give me photos and files across all of them. (I know Google Drive could but it didn’t exist until after I established my very well working system)
I use a paid Dropbox account because I use it for backup and daily use but the free option may be enough for you.
My phone and iPad both upload their photos to Dropbox- thus my photos are not only backed up but available everywhere.
Google keeps my email, calendar and contacts in sync across them all. I even use Outlook on occasion on my desktop but I find that Google’s web interface is faster and easier in most cases.
Does it all work? Yup. Can it adapt? I believe so.
Now, I do have to give Apple some credit for iCloud though. I started out with an iPhone 3 upgraded to a 4 and then got bored with iPhones after I got an iPad. I didn’t see the point of my phone and tablet being able to do the same thing. Why not have a phone that could do more and compliment it with an iPad? (that’s a whole other story)
iCloud did a great job of keeping my email, contacts, calendars and photos in sync. BUT, because my desktop and laptops are Windows there was a lot of hair pulling with iCloud’s Windows desktop components. Granted- Apple only supports Windows because it HAS to, not because it wants to. I get it but they need to do a better job. Not everyone wants a Mac.
iCloud’s web email client however blows. It sucks. Really really bad. Google wins for web email clients.
Thus the switch to Google for my primary email, contact and calendar use was a no brainer. Plus it works better on more platforms.
Ultimately my preference is for what works for me. I like things that just work.
Things that just work however have degrees. If you’re willing to take the time to set it up you can make anything just work. If you have all Apple products- they just work. That’s a credit to Apple.
If you have all Android/Google products they just work- not as seemless but well enough.
If you have a mix it gets complicated but it can be done.
At this point in the tech world you can have what ever combination of devices you want and they can all play nice.
The only exception I can see to that are native apps. Apps are specific to the device or OS you’re using and it’s getting more fragmented and complicated every day. But that’s a whole other topic.
My wife and I are ravenously divided on gun laws and ideals. I believe we should have the right to own guns. She thinks only law-enforcement should have them.
She’s starting to see it my way, especially in the context of home security but there is one area we both agree on.
There is NO reason any non-law-enforcement person/agency should have an assault rifle.
The reasoning is simple:
- You don’t hunt with them.
- They’re not concealable (within reason).
- They’re purpose is outside the scope of what a citizen should be doing.
Assault rifles were designed for one purpose. Killing people. Assaults on people. Assaults by law-enforcement. Not citizens.
What law abiding citizen needs to kill anyone? Never mind that it’s not legal or moral (in any country on the planet).
I agree you should be able to own:
- a hand gun for home or personal protection
- a shot gun for home protection or fowl hunting
- a hunting rifle for – hunting game aka animals
Outside of these reasons there isn’t much else you’d need a high powered people killing rifle for. An assault rifle will destroy a deer. If you’re not hunting deer for food you shouldn’t be hunting.
I know there are those the believe that we may some day need to protect ourselves from our own government.
I know there are those that believe that we may some day need to protect ourselves from a foreign government on our soil.
Do you honestly think that any legally available gun is going to match the US military? If the US government falls the military is the last thing you’re going to need to worry about.
When was the last time we were attacked on US soil? WWII. Hawaii. Would an assault rifle have helped you? Not likely.
Our little vinyl cutting adventure is now selling ban-assault-rifle stickers via eBay with 25% of the sale (not proceeds or profit- 25% off the top) going to the Brady Campaign to Prevent Gun Violence.
We need legislation. I know we will never eliminate assault rifles. I know we’ll never be able to protect ourselves in every situation and location.
I do know that it needs to be A LOT more difficult for civilians to get weapons like assault rifles.
Help us support the Brady Campaign by buying AND displaying our NO ASSAULT RIFLES stickers. It’s not about making money. It’s about showing support for a good cause.
Filed under: Brain Droppings, Tech Articles, Technology
Back in the 90s (and today) I listen to some songs on repeat for hours. I used to use a WAV file editor to selectively cut and paste my favorite parts of techno songs together to extend them from 5 minutes to 25+ minutes. It was mostly simple because they’re repetitive but it did take skill to make them sound authentic. The major benefit of doing this by hand was that I could repeat the parts I loved most. Now The Echo Nest has an online too that’s almost but not quite as good at looping your favorite tunes. It does save huge amounts of time if you’ve ever done this by hand!
Mind you this thing only works in Chrome and Safari for now but it’s still a neat way to extend that song that’s always on repeat….Just upload your song and hit play. You can even adjust how it loops. Very cool!
Good work Echo Nest!
Now let me save the song to disk with a specific length…
Just moved to the Amazon EC2 Cloud. Yippie! AND I’m running the RDS service for the back end database. Sweetness. There is definitely something to be said about hosting with Amazon. Sure you’re still using Linux “machines” now called “instances” but the control and speed of it all is just amazing.
Windows 7 can be a serious pain in the ass when deleting files. This may help:
- Take ownership of the file(s). Start a Command Prompt (cmd) as an administrator in the affected folder, and enter:
takeown /f file takeown /f directory /r
- Give yourself full rights on the file:
cacls file /G username:F
cacls can be used with wildcards and directory traversal: Security from the command line with CACLS.
Some of you many have heard already but here’s the official word.
It’s true. I’m a cutter. I admit it. I cut vinyl. Lots of it.
My wife and I have started a tiny business selling vinyl stickers.
It’s a great combination of her creativity, my technical skills and our love of sharing that with the world.
Sure, it’s been done. There’s LOTS of competition. We think that we can compete since our costs are really low and we can create literally anything.
Our main website is www.jnmvinylstudio.com
You can find our work on:
Our pricing varies a bit depending on the venue.
If you have any questions or have something you’d like made please just ask! What we have published are fairly common designs and it grows weekly.
Where I live- zip code 10901, AT&T Wireless service is generally good. With half signal bars I get good calls and data. Even in side. Verizon however doesn’t. So congratulations to AT&T Wireless. Sadly, I don’t need voice or data at home. Ever wonder why cell phones are referred to a mobile?
I ride a train to work every day. Two trips. Same route. Every day. About an hour and a half each way. That’s mobile. That’s when I need service.
AT&T Wireless sucks along this route. In some places there is NO SERVICE. The route? New Jersey Transit Bergen County Main Line/Port Jervis. Some stations along the line have perfect service. Sadly, since the train is moving, we’re not there long enough for it to matter.
To be fair, I am in a moving metal box. However, the Verizon customer sitting right next to me has perfect service. That’s just not acceptable.
I know what you’re saying- I’m using a iPhone- they have notoriously bad antennas. Maybe, but my shiny new iPad 3 with 4G gets great reception- full bars even. Those stations that have no service? Some have full 4G bars but no data can be sent/received. How does that work? Oh and just in case you’re wondering- I don’t exceed my 3GB data plan so AT&T Wireless should not be throttling me.
AT&T Wireless has a nice little smart phone app that I use A LOT on my iPad and iPhone. It’s called “Mark The Spot” It allows me to “report” issues. It even tells me when “new service” comes to an area I reported. Thanks! I think. Most of the time I can’t report the spot because–wait for it–there is no service. Does AT&T Wireless even read these reports? If they did, I am sure that I wouldn’t have the service problems I have. Sure they send me nice little text messages saying they got the report. I promise those are automated replies.
It gets more annoying. I spend a good amount of time in Penn Station New York (no thanks to NJT and Amtrak service issues). Guess who has service IN the station and IN the tunnels (all underground mind you)? Not AT&T Wireless. Verizon does though! Why is this I wonder? Could Verizon care enough to put femto or micro cells down there? I think AT&T Wireless doesn’t care. It’s most likely that they just don’t want to put femto or micro cells in the station or tunnels. Either way it makes their service suck and it frustrates me.
My midtown Manhattan office has similar AT&T Wireless issues. Dropped calls are the biggest problem here. But you say, “you’re in a huge building!” Yes I am. On the 18th floor in front of a window. Guess who never drops calls in our office? Verizon! You’d think that being high up and having a clear view would help. Doesn’t seem so. The service for AT&T Wireless at the street level is strangely perfect. I think those cell antennas need some adjusting.
Now you’re definitively thinking- why stay with AT&T Wireless? Well I initially blamed Apple because my beloved iPhone was only GSM and therefore only AT&T Wireless. That’s no excuse anymore!
I stay with AT&T Wireless primarily because they have great service where I live, which, generally is where I spend my free time. I had Verizon previously and because the service was so bad, all our cell phones would empty their batteries trying to connect to service while in the apartment. That’s a real bummer!
I honestly like AT&T Wireless. Their pricing and customer service haven’t been that bad. I have a family plan with 3 smartphones, 1 feature phone and 1 tablet. It’s affordable. Not affordable from a service perspective mind you….
So what’s this “rant” for anyway? Here’s what I want. I believe that I speak for A LOT of AT&T Wireless customers here.
PLEASE FIX YOUR NETWORK.
Stop adding 4G and LTE spots. Get the coverage fixed. 4G and LTE are useless if they don’t reach the customers. I live in a MAJOR metro area. New York is a BIG market. Service in the city stinks, I understand. Millions of cellular devices competing for air time. I get it. But on my train route? It’s suburbia. Low to medium density. Capacity shouldn’t be an issue out there.
Here’s what I’m doing about this besides writing long form rants. I use “Mark The Spot” EVERY DAY. I’m surprised I haven’t gotten a call from the “network” team at AT&T Wireless telling me to stop spamming them.
If we all use this app we can flood them with real data about the coverage issues. Of course I’m assuming they get the reports and really research them.
Spread the word. AT&T Wireless can be better. 4G is nice when it works. 3G that is consistent is much better. I’d even settle for Edge if it worked consistently.
I’ve been using cacti for network stat collection for years. In that time I’ve had to move cacti from one linux server to another. Keeping all the historical rrd data was of top priority. I just did another migration this morning. My notes were the key. I’m going to share them with you here.
A few things are assumed:
- you know how to use Samba and mount Samba shares between linux boxes
- CentOS 6.2 is the OS
- Cacti was installed from the Dag RPM Repository for Red Hat Enterprise Linux
- Your cacti path is /var/www/cacti
- You’ve used cacti before…
To start a quick outline of what needs to be done:
- install cacti on the new machine and verify that it is working!
- stop the poller on both cacti installs
- copy the old database to the new one
- copy your scripts and resources folders from the old to new (if you have any custom scripts)
- convert all old rrd files to xml files
- move/copy the xml files to the new cacti
- convert the xml files back to rrd format
- turn on the poller and test!
Why do the old rrd files need to be turned into xml files? rrdtool doesn’t like rrd files made on different machines. Even if they are identical machines/OSes. rrdtool is kind enough to allow you to export/import using the xml files to get around this.
Make note of which cacti machine each command needs to run on! Context is very important!
After installing the new cacti, make sure it’s working.
Next get samba setup on the old cacti machine and share the whole cacti folder. Security shouldn’t be an issue so you can share without the need for credentials.
Mount the rra folder on the new cacti machine, I used this command:
mount -t cifs //kny_netmon/root/var/www/cacti/rra /mnt/oldcacti
Copy over your scripts and resources folders from the old cacti to the new cacti. This should be done from the new cacti machine.
You can do the sql database export several ways. I chose to export the database on the old machine. I used this command:
mysqldump --user=root --password=password cacti > /var/www/cacti/newcacti.sql
If you want to do the sql export from the new machine you can do it like this (the resulting sql file will still be on the old cacti machine though):
ssh root@kny_netmon mysqldump --user=root --password=password cacti > /var/www/cacti/newcacti.sql
Next, import the database to the new cacti database, remember you’re on the new cacti machine for this command.
mysql cacti < /mnt/oldcacti/newcacti.sql
On the old cacti machine, do the xml export. Run this from the rra folder!:
for i in *.rrd; do rrdtool dump $i > $i.xml; done
On the new cacti machine, copy the xml files to the rra folder:
rsync -avz --exclude=*.rrd /mnt/oldcacti/ /var/www/cacti/rra
We don’t want the old rrd files so they’re excluded.
When the copy is done, on the new cacti convert the xml files back to rrd files:
for i in /var/www/cacti/rra/*.xml; do A=`echo $i|sed 's/\.xml//'`; rrdtool restore -f $i $A; done
Remove the old xml files from the new and old cacti:
rm /var/www/cacti/rra/*.xml -f
Now here’s the wacky part. In all my years I’ve setup cacti on Windows, CentOS, Debian, Ubuntu and MacOS. Permissions are ALWAYS an issue in the rra folder. I haven’t discovered the proper permissions so I just chmod them 777 and it seems to work. So unless you know the proper permissions just chmod them 777:
chmod 777 -R /var/www/cacti/*
I do the whole folder just in case….I know it’s BAD security but all my cacti installs are on private networks.
Start up the poller on the new cacti and start watching your log files and graphs. They should work!
My only issue on my last migration was that my snmp host only respond to certain IP addresses so I had to add the new cacti machines address. Otherwise it picked up where it left off.
For the sake of this “tutorial” I didn’t present any scripts.
when I do this “live” I’m able to literally get all this done in less than 5 minutes. Know why that’s important? Of course you do! The poller runs every 5 minutes.
If you can start at the end of the old cacti pollers cycle you can be ready for the next cycle on the new cacti. Pretty neat!
Don’t be afraid to test the procedure. All the copying/updating on the new cacti overwrites its settings. Each time you run this procedure you’re picking up the new/updated data from the old cacti.
You *could* leave the poller running on the old cacti if you want. I did, just making sure that the xml export was done in less than 5 minutes. I have about 900 rrd files so it’s fairly quick.