What would happen to the Internet during an alien invasion?*** INSUFFICIENT INFORMATION ***
Certain services (like social networking systems) would become flooded with hashtags about it, rendering them useless.
Amazon and E-bay would be flooded with requests for delivery of survival gear.
Social Network behavior would also change as smarter people seeking survival gear would stop generating meaningless noise and viewing cat videos and head out to local sporting goods shops for survival gear or grocery stores for non-perishable foods. Various right-wing nut jobs would be too busy selling guns and bullets from their gun shops to defend the NRA online.
The cell-phone system would collapse (like it did for 9/11) when all of the people trying to navigate out of town would impose excessive load trying to find their way out of town and to some safe place (any safe place.) It's hard to tell how that'd affect the Internet though - it might make it easier for the people who remain connected at work, school, or broadband to reach social networking sites and make meaningless comments and hashtags about the alien invasion.
There'd be a flood of email spam about how to survive the alien invasion, if you only give them personal information or your credit card information. (E-mail IS an internet service, not always on the web either.)
Sysadmins and network admins around the world would be called on to keep servers and services going. A lot of them will already have made provisions for a scenario like this and will either be unreachable (because they're ahead of the rest of the crowd seeking and provisioning a safe place for themselves and their families) or will (because they're geeky nerds) will have provisioned 1Gbps service in an undisclosed location well stocked with caffeinated colas, cheese-doodles, and pizza.
Even if it were not deliberately targeted it might still not be very useful long term. At least not in the way we use it now in most cases as a lot of other infrastructure would likely be either destroyed or damaged by almost all types of invasions.
Specifically disabling the internet would not likely be a high priority of any ET invasion plan, they'd be more concerned about cross contamination, military objectives and a number of other things such as destroying or disabling infrastructure that could aid humanity it it's fight or interfere with whatever it was they were planning to do.
Due to this, it could actually remain up and running in some localities for quite a while after any type of initial attack. However, and this is a big however, power and satellites would most likely be disabled or damaged. An EMP may also occur. These are things that are militarily important and would likely be targeted. Local networks would survive, but it's useless if the machines that access the information are down and out or running out of juice.
Sadly anyone dealing with an active alien invasion will also not think of being on the internet for any length of time. There are other things to concern yourself with at that time (such as surviving, hiding, fighting) so most may not think of harnessing it in event of an alien invasion. Those who have hardware able to be protected through most attacks will likely be the first ones targeted, and thus will be busy. (Military, Government agencies, etc). So those who could access it or retain information that was on the internet are likely to be few and far between. Unless most of it is done before an attack takes place; such as protecting your gear or backing up information which you might later need or find useful.
The first hints of attack would likely seep through social media rather quickly and could give people in areas not yet affected a short heads up since it's not directly likely to be disabled or destroyed outright. I'm sure at least one picture of the craft or the actual aliens would show up in someone's feed. Attacks in local areas might spread via twitter, or a picture of an EMP blast from a distance would end up on social media given how connected we are to our devices. The planet is a ridiculously large thing and most invaders will need to concern themselves with contamination issues and logistics so something might be noticed somewhere before everything went to hell. So while most people wouldn't get news or be able to post it - someone somewhere will post and some people somewhere will access before everything goes downhill.
One purpose the internet would serve though in the case of an alien invasion other than a potential heads up and warning system is as a reservoir of information. Many of us keep information on our devices and there are back -ups of much of it in various locations. This trove of information could help in any fighting or surviving. For instance, from making radios from scratch, farming, edible plants, biological information, first aid and anything else you can think of can come in handy. Many things you never thought you needed will also likely turn out to be very important, those who have that information will be well valued. Even if the only place you have it is your head from having read it on the internet before any attack occurred. In this case boredom, connectivity and reading up on various topics could save us.
Lastly the internet, in whichever forms the files were retained, could serve as a cultural archive to help after any invasion with information that might have been lost in hard copy. Since invasion often means destruction, mayhem and loss of infrastructure and specialists both our culture will suffer more than our cities. The cities likely won't look so nice anymore either and many books will be lost where a disk or flash drive might survive. In this light anyone who took it upon themselves to have information stored and secured in a place where survivors could access it months or even years after the conflict would potentially be credited with saving human civilization and progress. Even things as simple as midwifery, basic farming or making tools by iron working could save us in the end as many years may pass before we're ever at a point to recover completely.
Most people never think of these unconventional things in regards to alien invasions when it is precisely that type of stuff that would come in most handy were such to ever occur. The internet may very well save our civilization in such a case, even if it won't remain up and running long after any initial attack.
The word "invasion" is the issue. It would be equivalent to stating a question "while taking a shower, what would the water do if gravity failed". Aliens capable of reaching us would do pure research, nothing more. Here's why:
The accidental release of technology, to us, beyond our understanding would be detrimental to our and their existence in the short term and proximity. If this has occurred already, the visitors would recover it quickly, or humans smarter than myself would have the powers-that-be understand the dangers of having that technology. I think we're smarter than most give us credit for. We'd make the right choice, I hope, but visitors wouldn't be that dumb to let it happen.
An aggressive visitor would waste valuable resources invading. It doesn't make sense unless you think like a caveman, which many of us do. It's about time, distance and finite resource vs. gain. If visitors are capable of traveling here, energy isn't a need. Very few things beside knowledge would be in the need category.
An advanced culture can get resources necessary anywhere, earth isn't special there. Is it capable of supporting life? Yes, and that's DNA based carbon life forms breathing oxygen in a nitrogen rich atmosphere. Only we consider it special, because we cannot replicate it or control it.
I believe infiltration for knowledge is more likely.
I believe being created, or developed on purpose, we label it "God", is more likely.
Invasion makes for good drama, but not good sense. No differently than gravity failing.
It's easier to see when you flip it in the other foot. If WE get to the point where we visit another technical aware civilization, would we invade or learn? Is it possible we'd create vs. destroy? I think so. A politician/militaristic individual or group bent on power wouldn't ever be in charge. It doesn't make sense, the payoff for something like that only exists in writers brains.
Aliens with the smarts to get here and still have the gall to actually invade would most likely have the entire planet's communications all sussed out already. They would likely have figured out where the major hubs are and destroy them. Or... they would have divined a cyber attack that would render the Internet useless. So, the Internet would be dead in the most likely scenario.
If their goal was simply to annihilate all life on the planet then they would probably launch a coordinated attack from space. It would be over in minutes, if not seconds.
Alternatively, providing they're not that smart after all and their goal is to merely get humanity out of the way, and they miss that opportunity to create panic and confusion, the most likely scenario is that certain hubs would be quickly created to amass knowledge and tactics with which to avoid the attackers, provide assistance, and even how to fight back should it be necessary.
Facebook and similar social networks would be useless in this mode because isolated groups of friends and their friends would not normally be sufficient to spread the necessary information. It's more likely that the folks at home would be interested in what is happening everywhere at once, and would seek to amass a huge amount of information in a distributed network of custom sites for that purpose. Reddit or Slashdot and maybe even craigslist may be ideal for the purpose. Massively redundant server infrastructure would be best suited for the purpose, so you'd better hope Akamai or one of their competitors are in on the job. Ironically, despite the redundant architecture that was the main goal for creating the original ARPANET, much infrastructure is localized to a few regions (for example, Amazon's AWS). This makes disruption a fairly simple task. By spreading the information across many sites, and therefore many nodes, it would be more resistant to attack. In fact, I would be surprised if certain nations haven't already started working on this scenario for real. I mean, it could happen, and similar infrastructure would also be ideal for another World War situation.
As for me, I wouldn't get to see much of this. Cell phones would probably become useless very quickly as the network was disrupted by EMP emissions. I would be hiding out in the Marin Headlands or somewhere equally remote and uninteresting to an invader. I might still be there for several weeks after the invaders have capitulated, or be one of the last humans alive.
Used to control humans
If they are really smart they will have worked out that this is the greatest ever method of monitoring communications, influencing and subduing not just the population but the financial markets. All we might ever know is an increase in lolcats and trolls and a few more conspiracy theories, injected into the system by alien dumb-human-bots and designed to flood out any real information. (hmm - maybe that's already happened?)
Damaged or destroyed
If they are dumber and not really up to psychological warfare over our networks (as normally - implausibly - portrayed) and only slightly ahead of us in tech (as almost always portrayed) then presumably they can just take out the geosynchronous satellites pretty easily [Satellite Destroyers]. There are not many of them and they are basically sitting ducks.
The majority of the information is transmitted by undersea cable and these should be pretty easy targets too for anyone who is spacefaring and aggressive given that they know exactly where they run.
Actually, it would appear to be business as usual... right up until a saucer pulls up outside your house and beams you aboard for unspeakable forms of experimentation by bug-eyed monsters with large glowing fingers.
That's because any species smart enough to cross interstellar space would be capable of installing a 'great firewall' across all forms of media, including the internet.
Of course, the current obsession with social media is entirely to blame, as it's made us even more trusting of digital information, while making it even easier to carry out a global census to determine which humans are entertaining enough to be installed in the alien zoo, and which DNA prints should be preserved for future study, after the entire Earth is demolished to make way for a hyperspace expressway.