Thursday, June 19, 2014

Running Apache Websever (For PHP Development) on an Ubuntu Box

If you are doing any kind of PHP development, you’ll almost always be using Apache along with it. Here’s the quick and easy way to get PHP up and running on your Ubuntu box.

From a command shell, you will run the following commands:

sudo apt-get install apache2

sudo apt-get install php5

sudo apt-get install libapache2-mod-php5

sudo /etc/init.d/apache2 restart

Note that if apache is already installed you can omit the first line. Your web files will now be found in /var/www/

Friday, May 16, 2014

Emptying Ubuntu trash as Root

So I got stuck while using my Nautilus as root on Ubuntu 14.04. After I copied stuff to my Ubuntu off my Mac hard drive, I tired to delete some of the bits that I did not needed in my Ubuntu (which were copied from Mac). I figured I was using nautilus to access with other hard drive using root access which is why I needed root rights to empty trash can as well. So here is what I did:
sudo nautilus
^ This is what I did to access any hard drive as root and copy. I'm not sure if you have change rights with this but you sure can access and copy. (In my instance it was my Mac OS partition on the same notebook).
sudo rm -rf ~/.local/share/Trash/*
^ This command will empty trash as root. Both of these should be put into terminal for Ubuntu (Ctrl+T) will pop it up by default, in some cases you can find it in the Ubuntu side/search dock as well.

Thanks for reading!
Ciao :)

Thursday, May 8, 2014

Google Drive on Ubuntu 14.04

Note: Posting this after quite a few months folks, have been busy with Projects and assignments.


Anyways, so Its been a year and a half since I switched to Ubuntu and since then I've been in love with how you can break the barriers with a Linux Operating system. I upgraded to the 14.04 Long Term Support release a few days ago and thought that I should back up some of my data from drop box (being smaller in size) to Google Drive (15 gig storage on the cloud).

The Ubuntu Software center already proived a native Drop box app, but not for the google drive. So I googled and I found something!

Just to summarize it all, the you can go to the Ubuntu Terminal (Ctrl+T for most) and enter the commands mentioned below!






Wallah! You now have Google drive on your Ubuntu 14.04 :D

To setup Google drive after you have installed its package, type the command below in the terminal to configure. 

Tuesday, July 16, 2013

#Hashtag, Things I miss about Toronto.


This is a Mercury Cougar, formerly a Ford Automobile diversion department. It was a 1999 model that I dearly miss, it was technically my second car I bought being in Canada costed me around $1300 with around 150k clicks. Not bad for a used student car after all, eh? Well here goes the specs just for reference :)
  • Standard Engine: 2.5L V6
  • Standard Transmission: 5 Speed Manual
  • Cylinders: 6
  • Horsepower @RPM: 170@6250
  • Fuel Economy Cty/Hwy: 20/29
  • Combined Fuel Economy: 23
  • Fuel Type System: Gas Engine / Sequential Electronic Fuel Injected, Sequential Port Fuel Injected Sequential, Multi-Port Fuel Injected
  • Turbo (Yes/No): No
  • Overdrive Transmission: Yes
  • Compression: 9.7:1
  • Displacement: 2540/155
  • Bore X Stroke: 3.24x3.13

Sharing this one again


...to be continued.

Sorry about the wait from the last episode, got busy with a few things that have I thought I should sum up as follows:
> Preparing for Ramadan Kareem
> Being too lazy to blog while fasting
> Being a couch potato, preparing for RHCE - precisely a linux engineer.

Moreover, I went to another technician the other day, he promised he'd be able to help. The next day he called me up to ask me to pick up the notebook. I was surprised mean while I thought he might not have been able to fix the issue. Rushing to the store and stepping into find the notebook good as new, fixed for PKR2500. Not a bad fix after all, right? Seems that Integrated circuit placed over the display adapter had broken down, replacement probably didn't cost a fortune, but Oh well! saved me a fortune at least :)

Thursday, June 20, 2013

Freshly fried, red hot motherboard!

It's been really hot in Karachi these days, temperatures go up to 88F like today. My sister fried up her notebook's motherboard which is presumably the problem I troubleshooted. As the day went by I went to a local computer store near my house to get the problem fixed. Ranting around, trying to find the right store, I stepped into one of the fancy looking stores in the strip market. The sales man diverted me towards the "Technician" who was supposed to help resolve this issue. Lets not to forget how he managed to tell me that there was a display problem which is why the laptop wouldnt turn on. He kept the notebook for a good 24 hours and then returned it. He said it would cost me PKR 15,000 to get it fixed as the the motherboard and graphic card had fried up. I had partially lost hope...

Wednesday, June 19, 2013

The bugs present in my life

Since the past week malfunctions in my life include the following:
The error messages read: 
Error Code: 2013 Lost connection to MySQL server during query Error Code: 2006 MySQL server has gone away The timeouts are as follows: mysql> show variables like "%timeout%"; | Variable_name | Value | | connect_timeout | 10 | | delayed_insert_timeout | 300 | and more...


But on the other hand, I've been trying to improve track on what goes on in my life:
- Doing some cardio daily to loose those extra pounds
- Procastinating in the shower to over come malfuction and timeout in my programs
- Some more procastinating while re writing extensive lines of coding and still getting them wrong.
- ...And some more procastinating thinking of what movie to watch at this time of the night. I am flexing my bicep while I type this. 


Just so y'all know..

What up you all? I know its been long but undergrad has kept me drowned in my course work quite well. So blogging after prolly an year or more seems like a new beginning. I've been quite worried about the number of viewers on my blog going down. It dropped from 51 per day to probably like 7 people per day that read my blog.

Although I committed myself that I will make an interesting blog post tonight, I've thought of keeping it on the down low and give you all a very interesting post to look forward to..

This shall mark new beginnings on my blog. Stay tuned for some freshly baked posts every Friday!

Cheers! :-D

Monday, August 2, 2010

10 things I hate about the wedding season!

1. Why must I attend the mayun, mehndi, shaadi, valima, five dholkis AND a new-fangled pseudo-extremist dars for the wedding of my mother’s cousin’s son’s daughter? Why?!

2. The throngs of relatives arriving from abroad who decide to camp in your house because we Pakistanis are well-known for our strong family values and would rather die than suggest that our kin spend the wedding season in a hotel. Can I get an expletive in here?

3. Dance practice. And dances in general. Hasn’t the coordinated dancing trend gotten completely out of hand? Why are people taking professional trainers on for weddings? Isn’t inviting strangers to weddings just because they dance well completely insane? And if I have to do another coordinated dance combining bhangra with hip-hop moves just because that’s the done thing now (insert colourful expletive here).

4. I absolutely loathe that 45 minute drive to the wedding hall/outdoor tent which is inevitably delayed because the womenfolk (who happen to be the ones actually interested in attending) just can’t seem to find that set of bangles which matches that particular pair of shoes.

5. So you get to the wedding which is ultra crowded (because everyone wants to make ‘the scene yaar’) and you discover that the only table with free seats is the ‘old people’ table… ’nuff said.

6. The false smiles and running into people you hate in a setting where you simply don’t have the option of sticking a knife into them. Why must weddings be on such a grand scale that you end up inviting 40 people you abhor?

7. The overzealous banker-type yuppies who get hammered to prove they are not the sum of their MBA degrees, and the ancient aunty/uncle types who insist on dancing with the ‘bachas’ in an inebriated version of the cha-cha or samba.

8. Did I mention I hate the rishta brigade? Those gossiping ladies in the corner trying their hand at on-the-go matchmaking for the next wedding season. “Do you think that girl is too healthy for my son?” or “Mashallah, with a wallet like that, he must be a good catch.”

9. The obligatory 10,000 photos which each wedding season comes with. Fifty taken by the professional photographer, and 9,950 taken by giggly girls competing to see who can have the largest Facebook album of the season.

10. I hate the good food. If it wasn’t for the good food, I’d never go.



Published in The Express Tribune August 1st, 2010.

Monday, August 24, 2009

The call..

20th August. I received a call from Canadian High Commission verifying my information regarding my permit. I'm still waiting..
I'm annoyed, agitated, tensed whatsoever I'm off.

Stage 1-2

Alright so I applied for the visa on the 16th of July 2009. Since then I've been waiting and waiting. A few weeks back I received my passport with some missing documents checklist and a medical exam form which I had to take with the prescribed doctor by the Canadian embassy. So the missing documents were somewhat like this:

- Re submit passport after medical exam.
- Parent's Bank statements.
- Proof of relatives living in Canada.(Preferably their permanent resident card or Canadian passport)
- Proof of relation ship to sponsor. ( I did exactly understand what I had to attach with this but I got an affidavit made stating my relation ship to my sponsor and his signature and some of his private information, I Guess that should do the trick).
- Proof of Sponsors Business.(Business ownership papers and Tax papers).

After I was done with all these documents, I was unable to find a quick appointment with a doctor for a medical exam. Until I found a really good place called NMI(Neuro Medical Institute) which made my procedure wholesome and quick.

I instantly submitted my documents in about 2 days.

Since then I have no clue of when I'll be flying, for my classes start by 7th September.

:: Stage 1-2 ::
*..The Wait..*

Wednesday, March 4, 2009

The car that got robbed!

It was just a usual morning at our house with all our busy schedules
My father left home at 9:30, his drive to his office is about 30 minutes. Once he reached just near the office, he saw two men on a bike that were continuously following him, he did not notice but as he was parking his car they stopped (of course they showed him a pistol) him told him to shift at the back seat of the car. Drove him to the street near by, then they told him to get out of the car and they left with the car + all that the things the car contained. They gave him his Oakley shades back though :P
My dad called me from an unknown number and told me to call him back.
I called him and he told me the scenario I mentioned above, thanks to the person that helped him by dropping him off to his office and letting him use his cell phone.

The car contained a Dell inspiron 6000 with all the email backup and data in it.
A black berry curve that contained the copy of email data and importantly the CONTACTS.
All the check books, credit/debit cards, National ID card, license and Contact cards that were kept in the wallet.
And of course my Audio CD's :(

A blasphemy that happened to us, I though of sharing here.

Tuesday, January 13, 2009

Palm Unveils an iPhone Competitor!



Palm Unveils iPhone Competitor, the Pre

For Further information check out the article
HERE

Otherside of the story, Facebook scholars.

Each day about 1,700 juniors at an East Coast college log on to Facebook.com to accumulate “friends,” compare movie preferences, share videos and exchange cybercocktails and kisses. Unwittingly, these students have become the subjects of academic research.

To study how personal tastes, habits and values affect the formation of social relationships (and how social relationships affect tastes, habits and values), a team of researchers from Harvard and the University of California, Los Angeles, are monitoring the Facebook profiles of an entire class of students at one college, which they declined to name because it could compromise the integrity of their research.

In other words, Facebook — where users rate one another as “hot or not,” play games like “Pirates vs. Ninjas” and throw virtual sheep at one another — is helping scholars explore fundamental social science questions.

Facebook’s network of 58 million active users and its status as the sixth-most-trafficked Web site in the United States have made it an irresistible subject for many types of academic research.

But it is Facebook’s role as a petri dish for the social sciences — sociology, psychology and political science — that particularly excites some scholars, because the site lets them examine how people, especially young people, are connected to one another, something few data sets offer, the scholars say.

“For studying young adults,” said Vincent Roscigno, an editor of The American Sociological Review, “Facebook is the key site of the moment.”

But some scholars point out that Facebook is not representative of the ethnicity, educational background or income of the population at large, and its membership is self-selecting, so there are limits to research using the site. Eszter Hargittai, a professor at Northwestern, found in a study that Hispanic students were significantly less likely to use Facebook, and much more likely to use MySpace. White, Asian and Asian-American students, the study found, were much more likely to use Facebook and significantly less likely to use MySpace.

Facebook began in 2004 at Harvard and was restricted to students until 2006. As Ms. Hargittai points out in her paper, “Requiring such an affiliation clearly limited the number and types of people who could sign up for the service in the beginning.”

But Derrick B. Clifton, 19, a student at Pomona College in California, said, “I don’t feel like academic research has a place on a Web site like Facebook.” He added that if it was going to happen, professors should ask students’ permission.

Professor Hargittai of Northwestern conducted her Facebook study through a writing course that is required of all students at the University of Illinois, Chicago. Some 1,060 participants answered survey questions on paper. Professor Ellison of Michigan State used a random sample of 800 undergraduates who were invited to participate via an e-mail message that included a link to an online survey.

“Employers are looking at people’s online postings and Googling information about them, and I think researchers are right behind them,” said Dr. Christakis, a sociologist and internist who was an author of a study that received wide attention this year for its suggestion that obesity is “socially contagious.” (The researchers did not use Facebook.)

Among other topics, the Harvard-U.C.L.A. researchers are investigating a concept, first put forth by the pioneering German sociologist Georg Simmel, known as triadic closure: whether one’s friends are also friends of one another. If this seems trivial, consider that a study in 2004 in The American Journal of Public Health suggested that adolescent girls who are socially isolated and whose friends are not friends with one another experienced more suicidal thoughts.