Italiani, meno pallone, meno fica e piu’ Huxley!

Italian people, less football, less pussy and more Huxley!

Transcript below.

ALDOUS HUXLEY SPEECH UNEDITED

The Ultimate Revolution

March 20, 1962

Berkeley Language Center – Speech Archive SA 0269

Moderator:

{garbled}Aldous Huxley, a renowned Essayist and Novelist who during the spring semester is residing at the university in his capacity of a Ford research professor. Mr. Huxley has recently returned from a conference at the Institute for the study of Democratic Institutions in Santa Barbara where the discussion focused on the development of new techniques by which to control and direct human behavior.

Traditionally it has been possible to suppress individual freedom through the application of physical coercion through the appeal of ideologies through the manipulation of man’s physical and social environment and more recently through the techniques, the cruder techniques of psychological conditioning. The Ultimate Revolution, about which Mr. Huxley will speak today, concerns itself with the development of new behavioral controls, which operate directly on the psycho-physiological organisms of man. That is the capacity to replace external constraint by internal compulsions. As those of us who are familiar with Mr. Huxley’s works will know, this is a subject of which he has been concerned for quite a period of time. Mr. Huxley will make a presentation of approximately half an hour followed by some brief discussions and questions by the two panelists sitting to my left, Mrs. Lillian {garbled} and Mr. John Post. Now Mr. Huxley.

Huxley: Thank You.

{Applause}

Uh, First of all, the, I’d like to say, that the conference at Santa Barbara was not directly concerned with the control of the mind. That was a conference, there have been two of them now, at the University of California Medical center in San Francisco, one this year which I didn’t attend, and one two years ago where there was a considerable discussion on this subject. At Santa Barbara we were talking about technology in general and the effects it’s likely to have on society and the problems related to technological transplanting of technology into underdeveloped countries.

Well now in regard to this problem of the ultimate revolution, this has been very well summed up by the moderator. In the past we can say that all revolutions have essentially aimed at changing the environment in order to change the individual. I mean there’s been the political revolution, the economic revolution, in the time of the reformation, the religious revolution. All these aimed, not directly at the human being, but at his surroundings. So that by modifying the surroundings you did achieve, did one remove the effect of the human being.

Today we are faced, I think, with the approach of what may be called the ultimate

revolution, the final revolution, where man can act directly on the mind-body of his fellows. Well needless to say some kind of direct action on human mind-bodies has been going on since the beginning of time. But this has generally been of a violent nature. The Techniques of terrorism have been known from time immemorial and people have employed them with more or less ingenuity sometimes with the utmost cruelty, sometimes with a good deal of skill acquired by a process of trial and error finding out what the best ways of using torture, imprisonment, constraints of various kinds.

But, as, I think it was (sounds like Mettenicht) said many years ago, you can do everything with {garbled} except sit on them. If you are going to control any population for any length of time, you must have some measure of consent, it’s exceedingly difficult to see how pure terrorism can function indefinitely. It can function for a fairly long time, but I think sooner or later you have to bring in an element of persuasion an element of getting people to consent to what is happening to them.

It seems to me that the nature of the ultimate revolution with which we are now faced is precisely this: That we are in process of developing a whole series of techniques which will enable the controlling oligarchy who have always existed and presumably will always exist to get people to love their servitude. This is the, it seems to me, the ultimate in malevolent revolutions shall we say, and this is a problem which has interested me many years and about which I wrote thirty years ago, a fable, Brave New World, which is an account of society making use of all the devices available and some of the devices which I imagined to be possible making use of them in order to, first of all, to standardize the population, to iron out inconvenient human differences, to create, to say, mass produced models of human beings arranged in some sort of scientific caste system.

Since then, I have continued to be extremely interested in this problem and I have noticed with increasing dismay a number of the predictions which were purely fantastic when I made them thirty years ago have come true or seem in process of coming true.

A number of techniques about which I talked seem to be here already. And there seems to be a general movement in the direction of this kind of ultimate revolution, a method of control by which a people can be made to enjoy a state of affairs by which any decent standard they ought not to enjoy. This, the enjoyment of servitude, Well this process is, as I say, has gone on for over the years, and I have become more and more interested in what is happening.

And here I would like briefly to compare the parable of Brave New World with another parable which was put forth more recently in George Orwell’s book, Nineteen Eighty-Four. Orwell wrote his book between, I think between 45 and 48 at the time when the Stalinist terror regime was still in Full swing and just after the collapse of the Hitlerian terror regime. And his book which I admire greatly, it’s a book of very great talent and extraordinary ingenuity, shows, so to say, a projection into the future of the immediate past, of what for him was the immediate past, and the immediate present, it was a projection into the future of a society where control was exercised wholly by terrorism and violent attacks upon the mind-body of individuals.

Whereas my own book which was written in 1932 when there was only a mild dictatorship in the form of Mussolini in existence, was not overshadowed by the idea of terrorism, and I was therefore free in a way in which Orwell was not free, to think about these other methods of control, these non-violent methods and my, I’m inclined to think that the scientific dictatorships of the future, and I think there are going to be scientific dictatorships in many parts of the world, will be probably a good deal nearer to the brave new world pattern than to the 1984 pattern, they will a good deal nearer not because of any humanitarian qualms of the scientific dictators but simply because the BNW pattern is probably a good deal more efficient than the other.

That if you can get people to consent to the state of affairs in which they’re living. The state of servitude the state of being, having their differences ironed out, and being made amenable to mass production methods on the social level, if you can do this, then you have, you are likely, to have a much more stable and lasting society. Much more easily controllable society than you would if you were relying wholly on clubs and firing squads and concentration camps. So that my own feeling is that the 1984 picture was tinged of course by the immediate past and present in which Orwell was living, but the past and present of those years does not reflect, I feel, the likely trend of what is going to happen, needless to say we shall never get rid of terrorism, it will always find its way to the surface.

But I think that insofar as dictators become more and more scientific, more and more concerned with the technically perfect, perfectly running society, they will be more and more interested in the kind of techniques which I imagined and described from existing realities in BNW. So that, it seems to me then, that this ultimate revolution is not really very far away, that we, already a number of techniques for bringing about this kind of control are here, and it remains to be seen when and where and by whom they will first be applied in any large scale.

And first let me talk about the, a little bit about the, improvement in the techniques of terrorism. I think there have been improvements. Pavlov after all made some extremely profound observations both on animals and on human beings. And he found among other things that conditioning techniques applied to animals or humans in a state either of psychological or physical stress sank in so to say, very deeply into the mind-body of the creature, and were extremely difficult to get rid of. That they seemed to be embedded more deeply than other forms of conditioning.

And this of course, this fact was discovered empirically in the past. People did make use of many of these techniques, but the difference between the old empirical intuitive methods and our own methods is the difference between the, a sort of, hit and miss craftsman’s point of view and the genuinely scientific point of view. I think there is a real difference between ourselves and say the inquisitors of the 16th century. We know much more precisely what we are doing, than they knew and we can extend because of our theoretical knowledge, we can extend what we are doing over a wider area with a greater assurance of being producing something that really works.

In this context I would like to mention the extremely interesting chapters in Dr. William (sounds like Sergeant’s) Battle for the Mind where he points out how intuitively some of the great religious teachers/leaders of the past hit on the Pavlovian method, he speaks specifically of Wesley’s method of producing conversions which were essentially based on the technique of heightening psychological stress to the limit by talking about hellfire and so making people extremely vulnerable to suggestion and then suddenly releasing this stress by offering hopes of heaven and this is a very interesting chapter of showing how completely on purely intuitive and empirical grounds a skilled natural psychologist, as Wesley was, could discover these Pavlovian methods.

Well, as I say, we now know the reason why these techniques worked and there’s no doubt at all that we can if we wanted to, carry them much further than was possible in the past. And of course in the history of, recent history of brainwashing, both as applied to prisoners of war and to the lower personnel within the communist party in China, we see that the Pavlovian methods have been applied systematically and with evidently with extraordinary efficacy. I think there can be no doubt that by the application of these methods a very large army of totally devoted people has been created. The conditioning has been driven in, so to say, by a kind of psychological iontophoresis into the very depths of the people’s being, and has got so deep that it’s very difficult to ever be rooted

out, and these methods, I think, are a real refinement on the older methods of terror because they combine methods of terror with methods of acceptance that the person who is subjected to a form of terroristic stress but for the purpose of inducing a kind of voluntary quotes acceptance of the state the psychological state in which he has been driven and the state of affairs in which he finds himself.

So there is, as I say, there has been a definite improvement in the, even in the techniques of terrorism. But then we come to the consideration of other techniques, non-terroristic techniques, for inducing consent and inducing people to love their servitude. Here, I don’t think I can possibly go into all of them, because I don’t know all of them, but I mean I can mention the more obvious methods, which can now be used and are based on recent scientific findings. First of all there are the methods connected with straight suggestion and hypnosis.

I think we know much more about this subject than was known in the past. People of course, always have known about suggestion, and although they didn’t know the word ‘hypnosis’ they certainly practiced it in various ways. But we have, I think, a much greater knowledge of the subject than in the past, and we can make use of our knowledge in ways, which I think the past was never able to make use of it. For example, one of the things we now know for certain, that there is of course an enormous, I mean this has always been known a very great difference between individuals in regard to their suggestibility. But we now know pretty clearly the sort of statistical structure of a population in regard to its suggestibility. Its very interesting when you look at the findings of different fields, I mean the field of hypnosis, the field of administering placebos, for example, in the field of general suggestion in states of drowsiness or light sleep you will find the same sorts of orders of magnitude continually cropping up.

You’ll find for example that the experienced hypnotist will tell one that the number of people, the percentage of people who can be hypnotized with the utmost facility (snaps), just like that, is about 20%, and about a corresponding number at the other end of the scale are very, very difficult or almost impossible to hypnotize. But in between lies a large mass of people who can with more or less difficulty be hypnotized, that they can gradually be if you work hard enough at it be got into the hypnotic state, and in the same way the same sort of figures crop up again, for example in relation to the administration of placebos.

A big experiment was carried out three of four years ago in the general hospital in Boston on post-operative cases where several hundred men and woman suffering comparable kinds of pain after serious operations were allowed to, were given injections whenever they asked for them whenever the pain got bad, and the injections were 50% of the time were of morphine, and 50% of water. And about twenty percent of those who went through the experiment, about 20% of them got just as much relief from the distilled waters as from the morphea. About 20% got no relief from the distilled water, and in-between were those who got some relief or got relief occasionally.

So yet again, we see the same sort of distribution, and similarly in regard to what in BNW I called Hypnopaedia, the sleep teaching, I was talking not long ago to a man who manufactures records which people can listen to in the, during the light part of sleep, I mean these are records for getting rich, for sexual satisfaction (crowd laughs), for confidence in salesmanship and so on, and he said that its very interesting that these are records sold on a money-back basis, and he says there is regularly between 15% and 20% of people who write indignantly saying the records don’t work at all, and he sends the money back at once. There are on the other hand, there are over 20% who write enthusiastically saying they are much richer, their sexual life is much better (laughter) etc, etc. And these of course are the dream clients and they buy more of these records.

And in between there are those who don’t get much results and they have to have letters written to them saying “Go persist my dear, go on” (laughter) and you will get there, and they generally do get results in the long run.

Well, as I say, on the basis of this, I think we see quite clearly that the human populations can be categorized according to their suggestibility fairly clearly. I suspect very strongly that this twenty percent is the same in all these cases, and I suspect also that it would not be at all difficult to recognize and {garbled} out who are those who are extremely suggestible and who are those extremely unsuggestible and who are those who occupy the intermediate space. Quite clearly, if everybody were extremely unsuggestible organized society would be quite impossible, and if everybody were extremely suggestible then a dictatorship would be absolutely inevitable. I mean it’s very fortunate that we have people who are moderately suggestible in the majority and who therefore preserve us from dictatorship but do permit organized society to be formed. But, once given the fact that there are these 20% of highly suggestible people, it becomes quite clear that this is a matter of enormous political importance, for example, any demagogue who is able to get hold of a large number of these 20% of suggestible people and to organize them is really in a position to overthrow any government in any country.

And I mean, I think this after all, we had the most incredible example in recent years by what can be done by efficient methods of suggestion and persuasion in the form of Hitler. Anyone who has read, for example, Bullock’s “Life of Hitler”, comes forth with this horrified admiration for this infernal genius, who really understood human weaknesses I think almost better than anybody and who exploited them with all the resources then available. I mean he knew everything, for example, he knew intuitively this Pavlovian truth that condition installed in a state of stress or fatigue goes much deeper than conditioning installed at other times. This of course is why all his big speeches were organized at night. He speaks quite frankly, of course, in Mein Kampf, this is done solely because people are tired at night and therefore much less capable of resisting persuasion than they would be during the day. And in all his techniques he was using, he had discovered intuitively and by trial and error a great many of the weaknesses, which we now know about on a sort of scientific way I think much more clearly than he did.

But the fact remains that this differential of suggestibility this susceptibility to hypnosis I do think is something which has to be considered very carefully in relation to any kind of thought about democratic government. If there are 20% of the people who really can be suggested into believing almost anything, then we have to take extremely careful steps into prevent the rise of demagogues who will drive them on into extreme positions then organize them into very, very dangerous armies, private armies which may overthrow the government.

This is, I say, in this field of pure persuasion, I think we do know much more than we did in the past, and obviously we now have mechanisms for multiplying the demagogues voice and image in a quite hallucinatory way, I mean, the TV and radio, Hitler was making enormous use of the radio, he could speak to millions of people simultaneously. This alone creates an enormous gulf between the modern and the ancient demagogue. The ancient demagogue could only appeal to as many people as his voice could reach by yelling at his utmost, but the modern demagogue could touch literally millions at a time, and of course by the multiplication of his image he can produce this kind of hallucinatory effect which is of enormous hypnotic and suggestive importance.

But then there are the various other methods one can think of which, thank heaven, as yet have not be used, but which obviously could be used. There is for example, the pharmacological method, this is one of the things I talked about in BNW. I invented a hypothetical drug called SOMA, which of course could not exist as it stood there because it was simultaneously a stimulant, a narcotic, and a hallucinogen, which seems unlikely in one substance. But the point is, if you applied several different substances you could get almost all these results even now, and the really interesting things about the new chemical substances, the new mind-changing drugs is this, if you looking back into history its clear that man has always had a hankering after mind changing chemicals, he has always desired to take holidays from himself, but the, and, this is the most extraordinary effect of all that every natural occurring narcotic stimulant, sedative, or hallucinogen, was discovered before the dawn of history, I don’t think there is one single one of these naturally occurring ones which modern science has discovered.

Modern science has of course better ways of extracting the active principals of these drugs and of course has discovered numerous ways of synthesizing new substances of extreme power, but the actual discovery of these naturally occurring things was made by primitive man goodness knows how many centuries ago. There is for example, in the underneath the, lake dwellings of the early Neolithic that have been dug up in Switzerland we have found poppy-heads, which looks as though people were already using this most ancient and powerful and dangerous of narcotics, even before the days of the rise of agriculture. So that man was apparently a dope-bag addict before he was a farmer, which is a very curious comment on human nature.

But, the difference, as I say, between the ancient mind-changers, the traditional mind-changers, and the new substances is that they were extremely harmful and the new ones are not. I mean even the permissible mind-changer alcohol is not entirely harmless, as people may have noticed, and I mean the other ones, the non-permissible ones, such as opium and cocaine, opium and its derivatives, are very harmful indeed. They rapidly produce addiction, and in some cases lead at an extraordinary rate to physical degeneration and death.

Whereas these new substances, this is really very extraordinary, that a number of these new mind-changing substances can produce enormous revolutions within the mental side of our being, and yet do almost nothing to the physiological side. You can have an enormous revolution, for example, with LSD-25 or with the newly synthesized drug psilocybin, which is the active principal of the Mexican sacred mushroom. You can have this enormous mental revolution with no more physiological revolution than you would get from drinking two cocktails. And this is a really most extraordinary effect.

And it is of course true that pharmacologists are producing a great many new wonder drugs where the cure is almost worse than the disease. Every year the new edition of medical textbooks contains a longer and longer chapter of what are Iatrogenic diseases, that is to say diseases caused by doctors (laughter} And this is quite true, many of the wonder drugs are extremely dangerous. I mean they can produce extraordinary effects, and in critical conditions they should certainly be used, but they should be used with the utmost caution. But there is evidently a whole class of drugs effecting the CNS which can produce enormous changes in sedation in euphoria in energizing the whole mental process without doing any perceptible harm to the human body, and this presents to me the most extraordinary revolution. In the hands of a dictator these substances in one kind or the other could be used with, first of all, complete harmlessness, and the result would be, you can imagine a euphoric that would make people thoroughly happy even in the most abominable circumstances.

I mean these things are possible. This is the extraordinary thing, I mean after all this is even true with the crude old drugs. I mean, a housemate years ago remarked after reading Milton’s Paradise Lost, He Says “And beer does more than Milton can to justify God’s ways to man” (laughter). And beer is of course, an extremely crude drug compared to these ones. And you can certainly say that some of the psychic energizers and the new hallucinants could do incomparably more than Milton and all the Theologians combined could possibly do to make the terrifying mystery of our existence seem more tolerable than it does. And here I think one has an enormous area in which the ultimate revolution could function very well indeed, an area in which a great deal of control could be used by not through terror, but by making life seem much more enjoyable than it normally does. Enjoyable to the point, where as I said before, Human beings come to love a state of things by which any reasonable and decent human standard they ought not to love and this I think is perfectly possible.

But then, very briefly, let me speak about one of the more recent developments in the sphere of neurology, about the implantation of electrodes in the brain. This of course has been done in the large scale in animals and in a few cases its been done in the cases of the hopelessly insane. And anybody who has watched the behavior of rats with electrodes placed in different centers must come away from this experience with the most extraordinary doubts about what on Earth is in store for us if this is got a hold of by a dictator. I saw not long ago some rats in the {garbled} laboratory at UCLA there were two sets of them, one with electrodes planted in the pleasure center, and the technique was they had a bar which they pressed which turned on a very small current for a short space of time which we had a wire connected with that electrode and which stimulated the pleasure center and was evidently absolutely ecstatic was these rats were pressing the bar 18,000 times a day (laughter). Apparently if you kept them from pressing the bar for a day, they’d press it 36,000 times on the following day and would until they fell down in complete exhaustion (laughter) And they would neither eat, nor be interested in the opposite sex but would just go on pressing this bar {pounds on podium}

Then the most extraordinary rats were those were the electrode was planted halfway between the pleasure and the pain center. The result was a kind of mixture of the most wonderful ecstasy and like being on the rack at the same time. And you would see the rats sort of looking at is bar and sort of saying “To be or not to be that is the question”. (Laughter)

Finally it would approach {Pounds on podium} and go back with this awful I mean, the (sounds like franken huminizer anthropomorphizer), and he would wait some time before pressing the bar again, yet he would always press it again. This was the extraordinary thing.

I noticed in the most recent issue of Scientific American there’s a very interesting article on electrodes in the brains of chickens, where the technique is very ingenious, where you sink into their brains a little socket with a screw on it and the electrode can then be screwed deeper and deeper into the brainstem and you can test at any moment according to the depth, which goes at fractions of the mm, what you’re stimulating and these creatures are not merely stimulated by wire, they’re fitted with a miniature radio receiver which weighs less than an ounce which is attached to them so that they can be communicated with at a distance, I mean they can run about in the barnyard and you could press a button and this particular area of the brain to which the electrode has been screwed down to would be stimulated. You would get this fantastic phenomena, where a sleeping chicken would jump up and run about, or an active chicken would suddenly sit down and go to sleep, or a hen would sit down and act like she’s hatching out an egg, or a fighting rooster would go into depression.

The whole picture of the absolute control of the drives is terrifying, and in the few cases in which this has been done with very sick human beings, The effects are evidently very remarkable too, I was talking last summer in England to Grey Walter, who is the most eminent exponent of the EEG technique in England, and he was telling me that he’s seen hopeless inmates at asylums with these things in their heads, and these people were suffering from uncontrollable depression, and they had these electrodes inserted into the pleasure center in their brain, however when they felt too bad, they just pressed a button on the battery in their pocket and he said the results were fantastic, the mouth pointing down would suddenly turn up and they’d feel very cheerful and happy. So there again one sees the most extraordinary revolutionary techniques, which are now available to us.

Now, I think what is obviously perfectly clear is that for the present these techniques are not being used except in an experimental way, but I think it is important for us to realize what is happening to make ourselves acquainted with what has already happened, and then use a certain amount of imagination to extrapolate into the future the sort of things that might happen. What might happen if these fantastically powerful techniques were used by unscrupulous people in authority, what on Earth would happen, what sort of society would we get?

And I think it is peculiarly important because as one sees when looking back over history we have allowed in the past all those advances in technology which has profoundly changed our social and individual life to take us by surprise, I mean it seems to me that it was during the late 18 century early 19th century when the new machines were making possible the factory situation. It was not beyond the wit of man to see what was happening and project into the future and maybe forestall the really dreadful consequences which plagued England and most of western Europe and this country for sixty or seventy years, and the horrible abuses of the factory system and if a certain amount of forethought had been devoted to the problem at that time and if people had first of all found out what was happening and then used their imagination to see what might happen, and then had gone on to work out the means by which the worst applications of the techniques would not take place, well then I think western humanity might have been spared about three generations of utter misery which had been imposed on the poor at that time.

And the same way with various technological advances now, I mean we need to think about the problems with automation and more profoundly the problems, which may arise with these new techniques, which may contribute to this ultimate revolution. Our business is to be aware of what is happening, and then to use our imagination to see what might happen, how this might be abused, and then if possible to see that the enormous powers which we now possess thanks to these scientific and technological advances to be used for the benefit of human beings and not for their degradation. Thank You.

CREDITS: http://www.cuttingthroughthematrix.com/transcripts/Mass_Mind_Control_Alan_Watt.html

fsf

Defeating massive surveillance one step at time: Facebook

I decided to move to freedom.

This is a series of posts documenting how I’m doing it, a small step at time.

This academic article illustrates how facebook tracks you

There are some thing I assume we all should have understood so far, but sometimes I’m wrong, otherwise it wouldn’t be explainable how possibly people are still buying and using operating system like Windows or Mac OsX.

First simple step: Avoid Facebook tracking system.

I don’t want facebook to track me. I don’t want facebook to know whatever website I visit. That’s possible because many websites use the facebook like button which is not a simple image, but it’s the result of a javascript which is downloaded from facebook.net and executed on your browser. At the end of these two operation, the image is displayed.

So how to avoid this? There are weak point in that design. I will take advantage on one of these. This piece of code is already so diffused that they can’t change the domain name it comes from which is on ‘facebook.net’. So a very easy solution is to modify my hosts file (the file used with precedence on a dns hostname resolution in order to resolve the ip address of a given hostname) and I will force my machine to resolve the domain ‘facebook.net’ to 127.0.0.1 which is my loopback interface. This way, the javascript from facebook will never be downloaded by my browser, thus it will never be executed.

If you are using Windows or Mac OsX you have some other, bigger problems to solve first. So for this reason you may want to consider moving to more free operating system like Trisquel or Debian and its derivatives like Ubuntu.

Take a look at this interesting article on the Free Software Foundation website

 

cooking-android

Update Samsung Galaxy tab 7 aka GT-P1000 codename P1 to 2.2.3 and Get it Rooted

First: if you are here it’s because you feel that something is wrong with mobile phones, you are close, now: take a look here http://www.gnu.org/philosophy/android-and-users-freedom.html

This is just the beginning, and it seems to be a mandatory step in order to run Cyanogenmod 11 on my Galaxy tab and get rid of malicious Samsung backdoor(s).

the procedure involves an update to Android 2.2.3 in order to be able to properly run Clockwork recovery.

But what I did is putting all together (both the upgrade and the clockwork recovery) so it will be very easy for me to redo the process and for my neighbours to do the same as me in order to get rid of a couple of backdoors well documented on the Free Software Foundation website.

You can trust me or not for downloading the needed files. Personally I don’t trust the source I had these files from as the files were encrypted and available on gdrive.  I used the one linked from the Cyanogenmod wiki page on GT-P1000 and just in order to install Cyanogenmod over it… but I found weird that they are encrypted.
I downloaded packages from here: https://www.youtube.com/watch?v=iI79j97R4qw and as you can see my question about why encrypting files is still unanswered.
Why encrypting a zip file if not for avoiding gdrive to scan it for viruses? The best option at this point for me is repeating the entire process starting from the stock image (replacing just the kernel image), the one you get either when you buy the tab or when you do the latest firmware update available. At least that case we will be sure that it will contain just the back-door from Samsung and Google proprietary software. This very case what I needed was the Clockwork recovery in order to install Cyanogenmod.

Download here needed FIles from my Gdrive account.

Simply extract the zip archive into a folder, `cd` into that folder and use the command line below (this is mainly for me so I won’t struggle again if I need it again).

Last words i would like to spend about this is: I haven’t installed gapps as I don’t really need them. Why? Because I already have a browser and all those application are nothing else that browsers but with two more facets: first of all of them have so called helpers, which make those browsers more convenient to use) think about authentication and graphical optimization compared to usual mobile phone or tablet browser) Second: the can contain more than you need to run properly those web-services, they could contain back-doors triggered by so called push notifications. Basically nothing easier for criminal who want to steal your data.

So how to install an application for your new  fresh installed cyanogenmod?

Simple use F-droid and nothing else.

To complete this you need Heimdall. I used the Ubuntu version, so cmd parameters may differ with other operating systems version an from future version for this operating system.

Terminal command (please note that Heimdall for mac uses one single dash for distinguishing options instead on Ubuntu it uses two dashes):

heimdall flash --repartition --CACHE cache.rfs --DBDATAFS dbdata.rfs --FACTORYFS factoryfs.rfs --pit gt-p1000_mr.pit  --IBL+PBL boot.bin --MODEM modem.bin --PARAM param.lfs --SBL Sbl.bin --SBL2 Sbl.bin --KERNEL zImage --RECOVERY zImage --HIDDEN hidden.rfs --MOVINAND movinand.mst --verbose

After this you can easily install Cyanogenmod about which I will type a new post next weekend. I know it’s an old device but it’s still not bad at all and I think a lot of people could be interested in this.

Giuseppe

 

How I Fixed (unbrick) my Galaxy Tab 7 aka GT-P1000

Complete Fix for Galaxy GT-P1000

If you screwed like me your galaxy tab including partitions, but you still have chance to start it in Upload mode by pressing power button and volume down, this procedure will save your device.

A couple of remarks only.

Remark 1:
A lot of people claim to have a guide that works, but every single guide i tried just didn’t. So i decided to post this one for desperate people like me that will attempt any guide out there, with no result.

Remark 2 :
It’s moronic to use some file sharing or file upload service that will delete your files after a while or that will be shut down by feds after a while, so i used my google drive account.

GT-P1000 Complete package

Extract all files from above linked package into a directory

Heimdal for mac (the version i used)

Use the following command line to upload the files to your galaxy.

Cmd line command:

heimdall flash –repartition –CACHE cache.rfs –DBDATAFS dbdata.rfs –FACTORYFS factoryfs.rfs –pit gt-p1000_mr.pit  –IBL+PBL boot.bin –MODEM modem.bin –PARAM param.lfs –SBL Sbl.bin –SBL2 Sbl.bin –KERNEL zImage –RECOVERY zImage –HIDDEN hidden.rfs –MOVINAND movinand.mst –verbose

Not sure if it is really needed but after this operation i started the device in .. let’s call it install mode by pressing power button and volume up, together.

Then it restarted

If you are in trouble just drop me a comment, i usually answer within a couple of days or minutes ;)

Giuseppe

moodle-wordpress-single-sign-on

WordPress Moodle integration

A.K.A. WordPress and moodle SSO (Single Sign On).

There are these two very good open source content management and e-learning products:

WordPress

Moodle

I find this a very interesting argument, for this reason i started writing a guide about how to make users authenticate on both systems with a single sign on.

My post is about getting things running smoothly after wordpress updates.

That could be tricky because any updat on wordpress side or on moodle side will overwrite all modification made in order to make the SSO working.

You can take a look at my post about Moodle and WordPress integration.

Let me know if this works for you and what can goes wrong so I can update information there.

Giuseppe

fsf-12663

Member of Free Software Foundation

So finally it was time for me to join the right political party.

This is going to take a very long writing and right now I don’t have exactly the time that this argument deserves to write about it, so I will just tell you guys, that since yesterday 3rd of February 2014 I’m a happy sustaining member of the Free Software Foundation and I invite you all to do the same.

[FSF Associate Member]

At same this is the right occasion to say Goodbye to microsoft, apple, and company.

I’ll keep some of my accounts on evil social networks like facebook with the only purpose to inform people about how big companies do with their data, and for helping them to install the most convenient operating systems like Debian, Ubuntu, Trisquel.

Join this mailing list :http://lists.libreplanet.org/mailman/listinfo/libreplanet-discuss

Take a look at the Libre Planet website

Donate! You can’t spend your money a better way https://crm.fsf.org/civicrm/contribute/transact?reset=1&id=14

 

Have a free computing and join the fight until it’s too late!

Giuseppe

depot_logo

Multi System usb disk creator

Well i have to edit this, please just don’t use this software. It could really mess your pc partition up especially if you use LVM.

Sorry if I shared such low quality information. :(

 

For who doesn’t know yet this nice piece of software, this is the right chance to grab this useful program which let us create a bootable usb dongle or dc/dvd with several operating systems on board. This is a very convenient tool for who, for work or for personal study,  do several installations of operating systems.
Also this project is using GPLv3 which means that is free software.

All good, but the main website http://liveusb.info seems to be in French, which I don’t understand and google translator gives hilarious translations of it.  As it wasn’t enough the address of the repository from where installing the software is well buried between advertisements  and pay, buy, gimme-some-love buttons.

Download link as well.

For these two reasons I decided to write here a couple of useful links and since the project is Free Software, nobody will complain if I put a copy here, for non French speaking users like me, which includes me as well the next time I have to create such an USB BOOTABLE MULTISYSTEM STICK.

Repository and key first:

# # Add Depot of MultiSystem
sudo apt-add-repository 'deb http://liveusb.info/multisystem/depot all main'
# # Add the public key
wget-q-O - http://liveusb.info/multisystem / depot / multisystem.asc | sudo apt-key add -
# # Reload sources
sudo apt-get update
# # Install MultiSystem
sudo apt-get install multisystem

Users # Debian
# After installing multisystem add to your $ USER adm group.
sudo usermod-a-G adm “$ SUDO_USER”

Et voila’

Little advice: I couldn’t write complete instruction because the lates version changes often. This means that if I type complete commands, and you copy/paste them, the version you will try to install will mismatch with the one you will download. So just complete automatically my commands using tab after having pasted them into a terminal window (which you can open with the keyboard shortcut CTRL+ALT+T).

First of all dependences:
GtkDialog Amd64 for 64 bit machines

GtkDialog i386 for 32 bit machines

install with:

dpkg -i gtkdialog

In order to satisfy other prerequisites, type into a terminal:

sudo apt-get install -f

Download then
Debian/Ubuntu Amd64 for 64 bit machines

Debian/Ubuntu i386 for 32 bit machines

Install with:

sudo apt-get install multisystem

Then again:

sudo apt-get install -f

For the ones interested in sources, likek me,  unfortunately the only one available is the one for gtkdialog. I will ask the author where the sources are and how to download them as he claims this latter to be Free Software

http://code.google.com/p/gtkdialog/

Anyway the reason why I’m interested in this sources is because installation will fail if you use LVM :( because of grub-pc will not be able to install on any of your lvm partitions

Yo

Backupp

Installing and configuring Bareos (Bacula fork) with web front-end on Debian Wheezy.

And taking nice backups easy to be restored.

The story is quiet simple: some times ago I would have liked to have a kind of 8 months old backup for a friend of mine, but it was too late. So now, I want backups with a decent retention. So I can go “back in time” and recover files. Another choice could have been Subversion, but I’m going to backup images as well so, for this reason I’ll not take Subversion into consideration.

I’ll proceed with Bareos as it seems to be a Free Software fork of Bacula (so I hope it will be stable and robust as Bacula)  but with features that normally are sold as commercial by the Bacula project team.

I’ll use the Bareos official repository, where to download and install Bareos from.

Components

Bareos is made out of three main components and console:

  • - Director
  • - Storage Service
  • - File Daemon
  • Console

Not all of these components are needed for a client machine, let’s see what do we need in order to run the each component efficiently and start taking backups.

Before starting I’ll use this fantastic feature offered by Transip: the Snapshot. So if something goes wrong it will be very easy to rollback to the pre-screw-up image.

Some pre-requirements

These are required packages, if you already have them the following command doesn’t hurt.

apt-get -y install mysql-server apache2 php5 php5-mysql sudo

Then I will install their repositories and install Bareos from them like this:

URL=http://download.bareos.org/bareos/release/latest/Debian_7.0/
printf "deb $URL /\n" > /etc/apt/sources.list.d/bareos.list

# add package key
wget -q $URL/Release.key -O- | apt-key add -

apt-get update
apt-get install bareos bareos-database-mysql

If you are going to use the instructions on the Bareos website, please watch out the debian version which now is 6.0. So if you use Wheezy, just change the 6 into 7, as I did. Oh yes and in their example PostgreSQL is used in place of Mysql.

Some configuration to do.

For completing the Bareos configuration, we should setup the database and the tables and so there are some sql files to be executed, but for these files to work we need passwordless access to mysql for root. For some minutes only. If this was mysql5.6+ we could use the special variable –login-path=local, but we are on 5.5 so we can either create a .my_cnf in the root home directory or restarting mysql using the –skip-grant-tables option which will make mysql go with no passwords.

I’ll chose the second one. By the other things, this procedure is very useful in order to reset the mysql password without having a valid mysql account. So what to do is:

  • - Stop mysql
  • - Restart mysql with the –skip-grant-tables option
  • - Run scripts below
  • - Kill mysqld_safe
  • - Restart Mysql in normal mode using the usual init.d script.
/etc/init.d/mysql stop
/usr/bin/mysqld_safe --skip-grant-tables

At this point you should HIT CTRL+Z so you can continue using your terminal.
When finished you can get back to the mysqld_safe process by typing ‘fg‘ as requested later in this post. (CTRL+Z sends the process in background, ‘fg‘ instead brings it back to ForeGround).

/usr/lib/bareos/scripts/create_bareos_database
/usr/lib/bareos/scripts/make_bareos_tables
/usr/lib/bareos/scripts/grant_bareos_privileges

This last command gives some problems because you started mysql with the skip-grant-tables option so it cannot use those tables for executing queries.

Kill the mysql with –skip-grant-tables, as we don’t need it any more with:

fg
CTRL + C

Open the file /usr/lib/bareos/scripts/grant_mysql_privileges and change the line

if $bindir/mysql $* -uroot  -f <<END-OF-DATA

into

if $bindir/mysql $* -uroot -p -f <<END-OF-DATA

So the password will be requested as user input.

The Director

The file in /etc/bareos-dir.conf contains the main part of the configuration.  The main important sections and some very small explanations of them are:

  • JobDefs
    This defines element in common for two or more job so there is less configuration to write. They can contain almost all is contained in a Job
  • Job
    This define the client to backup, the fileset, the storage to use etc
  • Schedule
    This controls the timing of the jobs, define a schedule with a name here, and then use it by name in Job or JobDefs
  • FileSet
    This define a fileset to be used for a job, then the name of this fileset is used in Job or JobDefs
  • Client
    This define the client by name to be used in Job or JobDefs
  • Storage
    This Defines a storage by name to be used in Job or JobDefs
  • Catalog
    This defines the database where to store information about for example owner and file permissions.
  • Messages
    The Notification configuration
  • Pool
    The way storage devices (tapes or files) are managed.
  • Console
    This configures credentials fr using the console interacting with the director.

What to configure

After a fresh install, there is some basic configuration for Bareos in /etc/bareos. This configuration wants to illustrate how to set up various component but it is also working for making a backup of Bareos itself and the MySQL catalog.

Precisely there are 5 files and each of them has a sample configuration for the director itself in  order to backup both catalog and files.

I want to add pretty much the same thing : mysql database dumps and files coming from web dirs. But before doing this i want to know how much disk space a full backup is going to take so i can configure the storage and so.

1.3G web/

320M mysql/

So I’m going to need some space too have a long retention. Let’s just start with a ‘normal’ retention then we will always be able to increase  it. But meanwhile we can keep an eye on the backup files created on this side, monitoring their growth and being able so to have an estimation about the initial disk space needed.

I’m not going to use tapes for my backups, but a second machine will store the backups  (as data files) and those backup are nightly transferred at my place through a cron job which runs on a NAS running linux.

Speaking about the web folders and MySQL  here, means speaking about WordPress blogs, like this one, so what they do is basically adding new contents into the database, and new images and media on the disk. So the only part which could be neglected is WordPress itself, but since the disk space taken for those files is infinitely small compared to the images, we are going to backup those files as well, thus, by the way, we will have the plug-ins to be restored instead of guessing and installing plug-ins. So yes, it is definitely worth to save these file as well.

There are some configuration keys referenced in other configuration files. I’ll keep it consistent so do the same. These are for example, the storage.storage name, the storage.device name the fileset.name and so. The Device is defined in /etc/bareos/bareos-sd.conf, we’ll see later.

This is the Mysql part.

/etc/bareos/bareos-dir.conf

JobDefs {
    Name = MySqlDefs
    Type = Backup
    Level = Incremental
    Accurate = Yes
    Write Bootstrap = "/var/lib/bareos/%c-%n.bsr"
    Fileset = MysqlDumps
    Pool = MysqlPool
    Schedule = "WeeklyCycle"
    Storage = MysqlBackupStorage
    Messages = Standard
    Priority = 10
    Write Bootstrap = "/var/lib/bareos/%c.bsr"
    Write Bootstrap = "|/usr/sbin/bsmtp -h localhost -f \"\(Bareos\) \" -s \"Bootstrap for Job %j\" giuseppe@giuseppeurso.net"
}

Job {
  Name = "BackupMysql"
  Client = "Mysql"
  JobDefs = "MySqlDefs"
}

Client {
  Name = Mysql
  Address = 192.168.0.1
  Password = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
  File Retention = 30 days            # 30 days
  Job Retention = 6 months            # six months
  AutoPrune = yes                      # Prune expired Jobs/Files
}

Storage {
    Name = MysqlBackupStorage
    # N.B. Use a fully qualified name here
    Address = backupper.mylan.com 
    Password = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
    Device = FileStorageMysql
    Media Type = File
}

FileSet {
   Name = "MysqlDumps"
   Include {
     Options {
       signature = MD5
     }
     File = "/var/backups/server/mysql"
     File = "/etc/mysql/"
   }
}

Pool {
    Name = MysqlPool
    Pool Type = Backup
    Recycle = yes # Bareos can automatically recycle Volumes
    AutoPrune = yes # Prune expired volumes
    Volume Retention = 365 days
    Maximum Volume Bytes = 2G
    Maximum Volumes = 100
}

This is the web folders part with php scripts, images and so.

JobDefs {
 Name = WebDefs
 Type = Backup
 Level = Incremental
 Accurate = Yes
 Write Bootstrap = "/var/lib/bareos/%c-%n.bsr"
 Fileset = Webcopy
 Pool = WebPool
 Schedule = "WeeklyCycle"
 Storage = Web1BackupStorage
 Messages = Standard
 Priority = 10
 Write Bootstrap = "/var/lib/bareos/%c.bsr"
 Write Bootstrap = "|/usr/sbin/bsmtp -h localhost -f \"\(Bareos\) \" -s \"Bootstrap for Job %j\" giuseppe@giuseppeurso.net"
 }

Job {
 Name = "BackupWeb1"
 Client = "Web1"
 JobDefs = "WebDefs"
 }

Client {
 Name = Web1
 Address = 192.168.0.1
 Password = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
 File Retention = 30 days # 30 days
 Job Retention = 6 months # six months
 AutoPrune = yes # Prune expired Jobs/Files
 }

Storage { 
  Name = Web1BackupStorage
  # N.B. Use a fully qualified name here
  Address = backupper.mylan.com
  Password = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
  Device = FileStorageWeb
  Media Type = File
 }

FileSet {
 Name = "Webcopy"
    Include {
       Options {
           signature = MD5
        }
        File = "/var/www"
        File = "/etc/apache2/sites-available"
     }
 }

Pool {
 Name = WebPool
 Pool Type = Backup
 Recycle = yes # Bareos can automatically recycle Volumes
 AutoPrune = yes # Prune expired volumes
 Volume Retention = 365 days
 Maximum Volume Bytes = 2G
 Maximum Volumes = 100
 }

 

For the storage part we need to edit:

nano /etc/bareos/bareos-0sd.conf

and add one device for mysql backups and one for web backups:

Device {
 Name = FileStorageMysql
 Media Type = File
 Archive Device = /backups/bareos/storage
 LabelMedia = yes; # lets Bareos label unlabeled media
 Random Access = Yes;
 AutomaticMount = yes; # when device opened, read it
 RemovableMedia = no;
 AlwaysOpen = no;
}
Device {
 Name = FileStorageWeb
 Media Type = File
 Archive Device = /backups/bareos/storage
 LabelMedia = yes; # lets Bareos label unlabeled media
 Random Access = Yes;
 AutomaticMount = yes; # when device opened, read it
 RemovableMedia = no;
 AlwaysOpen = no;
}

Installing the client part

The following part is about installing the bareos client on the machine to be backed up. It will expose one service on a tcp port. We will make sure also that the two machines will talk each other using a private network.

We will call this machine, the one to be backed up, “Client”. As we already did for the server, let’s add the Bareos repository to our software package manager:

URL=http://download.bareos.org/bareos/release/latest/Debian_7.0/
printf "deb $URL /\n" > /etc/apt/sources.list.d/bareos.list

# add package key
wget -q $URL/Release.key -O- | apt-key add -

apt-get update
apt-get install bareos-client

At this point we need to configure roles and authentication between components to make it work and for this purpose the following image stolen from the bareos project website is very useful:

bareos-components-autentication

This image made very easy understanding who is who. In the case of the client we should take into consideration just the bareos-fd part.

At this point i restart the services on the server machine and on the client machine.

On server:

/etc/init.d/bareos-fd restart
/etc/init.d/bareos-sd restart
/etc/init.d/bareos-dir restart

And on Client

/etc/init.d/bareos-fd restart

Then I can use the bconsole to check what’s going on, it’s very easy, just enter into bconsole typing ‘bconsole’ and then ‘help’

bconsole
Connecting to Director eventhorizon:9101
Enter a period to cancel a command.
*help
 Command Description
 ======= ===========
 add Add media to a pool
 autodisplay Autodisplay console messages
 automount Automount after label
 cancel Cancel a job
 create Create DB Pool from resource
 delete Delete volume, pool or job
 disable Disable a job
 enable Enable a job
 estimate Performs FileSet estimate, listing gives full listing
 exit Terminate Bconsole session
 export Export volumes from normal slots to import/export slots
 gui Non-interactive gui mode
 help Print help on specific command
 import Import volumes from import/export slots to normal slots
 label Label a tape
 list List objects from catalog
 llist Full or long list like list command
 messages Display pending messages
 memory Print current memory usage
 mount Mount storage
 move Move slots in an autochanger
 prune Prune records from catalog
 purge Purge records from catalog
 quit Terminate Bconsole session
 query Query catalog
 restore Restore files
 relabel Relabel a tape
 release Release storage
 reload Reload conf file
 rerun Rerun a job
 run Run a job
 status Report status
 setbandwidth Sets bandwidth
 setdebug Sets debug level
 setip Sets new client address -- if authorized
 show Show resource records
 sqlquery Use SQL to query catalog
 time Print current time
 trace Turn on/off trace to file
 unmount Unmount storage
 umount Umount - for old-time Unix guys, see unmount
 update Update volume, pool or stats
 use Use specific catalog
 var Does variable expansion
 version Print Director version
 wait Wait until no jobs are running
When at a prompt, entering a period cancels the command.
You have messages.
*

The web front-end

Let’s find a convenient location where to download webacula and download it.

cd /var/tmp
svn co https://github.com/tim4dev/webacula webacula

This last command will download the entire svn of webacula. So we will use the latest version contained. First thing: make a folder for webacula under /var/www and then copy some folders into this folder

mkdir -p /var/www/webacula
cp -pr /var/tmp/webacula/trunk/html /var/www/webacula/
cp -pr /var/tmp/webacula/trunk/application /var/www/webacula/
cp -pr /var/tmp/webacula/trunk/data /var/www/webacula/
cp -pr /var/tmp/webacula/trunk/docs /var/www/webacula/
cp -pr /var/tmp/webacula/trunk/install /var/www/webacula/
cp -pr /var/tmp/webacula/trunk/languages /var/www/webacula/
cp -pr /var/tmp/webacula/trunk/library /var/www/webacula/
chown -R www-data.www-data /var/www/webacula
usermod -aG bareos www-data
chown root:bareos /usr/sbin/bconsole
chmod u=rw,g=r,o= /etc/bareos/bconsole.conf
cp /var/tmp/webacula/trunk/install/apache/webacula.conf /etc/apache2/sites-available/webacula.conf
sed -i 's/\/usr\/share/\/var\/www/' /etc/apache2/sites-available/webacula.conf
a2ensite webacula.conf
a2enmod rewrite
service apache2 restart
[Sat Dec 28 03:56:51 2013] [warn] module rewrite_module is already loaded, skipping
apache2: Syntax error on line 268 of /etc/apache2/apache2.conf: Syntax error on line 18 of /etc/apache2/sites-enabled/webacula.conf: /etc/apache2/sites-enabled/webacula.conf:18: <Directory> was not closed.
Action 'configtest' failed.
The Apache error log may have more information.
failed!

Don’t worry about the last error, I reported it here because probably a lot of people will have this problem with the tag 5.5.1 of Webacula. There is an easy fix which is adding a ‘<’ to the /etc/apache2/sites-enabled/webacula.conf file. Quiet easy. this is where to add it:

There is one line starting by

/Directory>

Note the missing opening ‘<’ , Instead of

</Directory>

This is what we need to change in order to fix the problem. Once done, save and restart Apache2

Now we need to make the user www-data capable to run the bconsole, in order to be able to read and write data. For this reason we need Sudo, so let’s install it and then we can add www-data to the sudoers file with a specific command.

apt-get install sudo
visudo

Add this line under the root one

www-data ALL=NOPASSWD: /usr/sbin/bconsole

At this point we need to download and install the Zend PHP framework minimal edition to make Webacula work. So download ZendFramework-1.12.3-minimal.tar.gz (check for the version number)  from http://www.zend.com/en/company/community/downloads. You will need a login (I know it sucks). Put it on /var/tmp

cd /var/tmp
tar -xzf ZendFramework-1.12.3-minimal.tar.gz
cp -pr /var/tmp/ZendFramework-1.12.3-minimal/library/Zend /var/www/webacula/library/Zend/

edit and configure the following file:

nano /var/www/webacula/application/config.ini

Remember to change

bacula.bconsole = "/sbin/bconsole"

into

bacula.bconsole = "/usr/sbin/bconsole"

And

bacula.bconsolecmd = "-n -c /etc/bacula/bconsole.conf"

into

bacula.bconsolecmd = "-n -c /etc/bareos/bconsole.conf"

Now it’s time to configure a database access for webacula. For this the developers provide us with some scripts. There is a configuration to be edited with database name, database password for root, before running the scripts:

nano /usr/src/webacula/trunk/install/db.conf
cd usr/src/webacula/trunk/install/MySql/
./10_make_tables.sh
./20_acl_make_tables.sh

There is one more thing to be fixed in order to make webacula run. Theoretically we have done now and we “should” be able to run our webapp at the address http://server/webacula. But, depending on your error reporting configuration for php, our result here will vary from a white page and an error page. I had a white one so i had to take a look at the error loga to see what was going on. The error log reported:

[Sat Dec 28 12:48:23 2013] [error] [client 10.0.0.1] PHP Fatal error:  Uncaught exception 'Zend_Exception' with message 'Bacula version mismatch for the Catalog database. Wanted 12, got 2001. ' in /var/www/webacula/html/index.php:186\nStack trace:\n#0 {main}\n  thrown in /var/www/webacula/html/index.php on line 186

This is probably due to the different versioning numbers going on between Bacula and Bareos. You will be tempted to  fix this from the database table “Version” which seems to be there exactly for this reason, but don’t because remember also bareos components use the database and they probably check that field as well (i did it actually, this is why I’m so damn sure). The solution is here https://github.com/bareos/contrib-webacula/blob/bareos-master/application/config.ini and I shouldn’t have used a tag… anyway, just open index.php and look for this line

define('BACULA_VERSION', 12); // Bacula Catalog version

And replace it with this one

define('BACULA_VERSION', 2001); // Bacula Catalog version

Before you start using bareos you have to lable the Volumes using the bconsole. The following is an example made with the configuration explained here:

bconsole 
Connecting to Director eventhorizon:9101
Enter a period to cancel a command.
*label
Automatically selected Catalog: MyCatalog
Using Catalog "MyCatalog"
The defined Storage resources are:
 1: File
 2: MysqlBackupStorage
 3: Web1BackupStorage
Select Storage resource (1-3): 1
FileStorage
Defined Pools:
 1: Default
 2: File
 3: Scratch
 4: MysqlPool
 5: WebPool
Select the Pool (1-5): 1
Connecting to Storage daemon File at eventhorizon.giuseppeurso.net:9103 ...
Sending label command for Volume "FileStorage" Slot 0 ...
3000 OK label. VolBytes=211 Volume="FileStorage" Device="FileStorage" (/backups/bareos)
Catalog record for Volume "FileStorage", Slot 0 successfully created.
Requesting to mount FileStorage ...
3906 File device ""FileStorage" (/backups/bareos)" is always mounted.
You have messages.
*label
The defined Storage resources are:
 1: File
 2: MysqlBackupStorage
 3: Web1BackupStorage
Select Storage resource (1-3): 2
Enter new Volume name: MysqlStorage
Defined Pools:
 1: Default
 2: File
 3: Scratch
 4: MysqlPool
 5: WebPool
Select the Pool (1-5): 4
Connecting to Storage daemon MysqlBackupStorage at 192.168.0.2:9103 ...
Sending label command for Volume "MysqlStorage" Slot 0 ...
3000 OK label. VolBytes=214 Volume="MysqlStorage" Device="FileStorageMysql" (/var/lib/bareos/storage)
Catalog record for Volume "MysqlStorage", Slot 0 successfully created.
Requesting to mount FileStorageMysql ...
3906 File device ""FileStorageMysql" (/var/lib/bareos/storage)" is always mounted.
*label
The defined Storage resources are:
 1: File
 2: MysqlBackupStorage
 3: Web1BackupStorage
Select Storage resource (1-3): 1
Enter new Volume name: Web1Storage
Defined Pools:
 1: Default
 2: File
 3: Scratch
 4: MysqlPool
 5: WebPool
Select the Pool (1-5): 5
Connecting to Storage daemon File at eventhorizon.giuseppeurso.net:9103 ...
Sending label command for Volume "Web1Storage" Slot 0 ...
3000 OK label. VolBytes=211 Volume="Web1Storage" Device="FileStorage" (/backups/bareos)
Catalog record for Volume "Web1Storage", Slot 0 successfully created.
Requesting to mount FileStorage ...
3906 File device ""FileStorage" (/backups/bareos)" is always mounted.
*label
Automatically selected Catalog: MyCatalog
Using Catalog "MyCatalog"
The defined Storage resources are:
     1: File
     2: MysqlBackupStorage
     3: Web1BackupStorage
Select Storage resource (1-3): 1
Enter new Volume name: FileSTorage
Defined Pools:
     1: Default
     2: File
     3: Scratch
     4: MysqlPool
     5: WebPool
Select the Pool (1-5): 2
Connecting to Storage daemon File at eventhorizon.giuseppeurso.net:9103 ...
Sending label command for Volume "FileSTorage" Slot 0 ...
3000 OK label. VolBytes=208 Volume="FileSTorage" Device="FileStorage" (/backups/bareos)
Catalog record for Volume "FileSTorage", Slot 0  successfully created.
Requesting to mount FileStorage ...
3001 OK mount requested. Device="FileStorage" (/backups/bareos)
*quit

You will get also this error:

SQLSTATE[42S22]: Column not found: 1054 Unknown column 'Media.VolParts' in 'field list'

I honestly don’t know what that field is spposed to contain but i want my app to work so i just create that field as a varchar 255 like this:

 mysql -uroot -p -e "use bareos; alter table Media add VolParts varchar (255);"

This should be all. Now point yur browser to the address where webacula is supposed to answer and check if you see the login prompt like this:

webacula_login_form

 

Username is root, the password is the one you choose while configuring the sql install script

That’s it. If you have comments or questions, please just use the form below this article.

Ciao

 

P.S.

I want to add this information: In this post I used fictional names for machines and for machines addresses. So I had some trouble once put this configuration working and I spotted a couple of typos and I had to fix the various passwords in various configuration files.

This image illustrates better:

webacula-after-tuning

This was Installing and configuring Bareos on Debian squeeze/wheezy with web front-end

storage-wide-load

Debian, managing LVM on a live system.

Playing with LVM on Debian Weehzy.

Resizing or deleting  partitions, gaining space and then redistribute it across the partition you need to resize.

Basically the logical operations are pretty simple and straightforward if taken into a ‘logical’ vie. Of course you have to shrink the partition first and then the volume, while, at the opposite if you want to grow a partition you have to resize the volume in order to be able to contain the bigger partition.

But you can’t do this on a running system. You have to restart into recovery mode. So you will be able to umount partitions as you will be using just the memory.

Particularly this applies to the machine from a dutch provider called Transip  who sells these convenient VPS and more, these have huge a disk space amount (the basic VPS has 50 gigs).

They offer a very nice Control Panel, although in dutch, is very easy to use and it offers advanced features like the chance to set the reverse dns by yourself, or or creating a private network with your virtual machine in order to carry on internal operation such as for example backups, or build your load balancing, your mysql cluster and so. Very very nice, their interface is built by themselves, very smart company.

Anyway, back to my problem, they have this console you can use to install the operating system from scratch and Icouldn’t manage to get into a partition manager that  allowed me to decide how many and how large partition to use. So i had to use one of the predefined setup (“Use entire disk and setup LVM” then “Use separate partition like /usr, / home, /var etc”).  This is a picture of the starting situation:

partition scheme transip

But I don’t really enjoy that kind of partitions and their size. So I’ll let the installation finish and then I’ll start modifying my lvm.

This machine will be used to keep some backups from mysql and some web folders under /var/www, from another machine. For this reason I will install and configure Bareos.

 

With “df -h” i can identify the following partitions, the ones I’m interested in. I want to get some free space from shrinking /home and merging /usr into the root partition (/):

/home 36 Gb
/    322 Mb
/tmp  368Mb
/usr   8.3Gb
/var   2.8 Gb
/blah

First, I want to get rid of /usr and merge it with / (the root partition).

For this reason I will:

cp -pr /usr /home/usr
umount /dev/machine-name/usr
lvremove /dev/machine-name/usr

then with

vgdisplay

I’ll be able to check the actual free disk space gained. You should see at the end of the output a line starting by (look at the picture below):

Free PE / Size.

That is the measure you can increase another partition of, or of the redistributable space. Here I’m going to make backups so I’m going to create a new partition called “/backups” where I will store my backups. This is supposed to be a very big partition, so i’ll start merging and shrinking partitions in order to leave the most of the space available for backups.

So now for example I’ll reduce the filesystem first and then teh volume size for the partition /home.

umount /dev/machine-name/home
e2fsck -f /dev/machine-name/home -p 2G
lvreduce -L 2G /dev/machine-name/home

Then this is what I have after all these operations:

after shrinking and deleting partitions and volumes

 

 

At this point I have still to merge /usr into / (the root partition), but i have to make it bigger first. So I’ll give more space to the logical volume first and then I’ll extend the file system as well.

lvextend -L 3G /dev/machine-name/root
resize2fs -p /dev/machine-name/root 3G
rm -fr /usr
mv /home/usr /

At this point we want to remove the /usr entry from /etc/fstab otherwise we will get errors because that partition doesn’t exist any more on our system. (little advice: since we are going to create a new partition and a new mount point at this point you could consider instead of deleting the entry, to modify it for the new mount point so there will be no need to come back on this file again, but it’s up to you).

 

Then create a new partition , but first the logical volume

lvcreate -L 39G -n backups vg-name

Create then a file system

 

 

mkfs .ext4 /dev/machine-name/backups

Let’s create a mount point

mkdir /backups

and let’s add the partition to /etc/fstab (just copy the line for /var taling care of renaming where needed)

If it’s all ok now we can reboot in a normal way and check whether the new partition mounts correctly etc.

So, reboot and connect with ssh. Then with “df -h” i’ll verify all.

root@eventhorizon:~# df -h
Filesystem Size Used Avail Use% Mounted on
rootfs 3.0G 308M 2.5G 11% /
udev 10M 0 10M 0% /dev
tmpfs 101M 232K 101M 1% /run
/dev/mapper/eventhorizon-root 3.0G 308M 2.5G 11% /
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 201M 0 201M 0% /run/shm
/dev/vda1 228M 18M 199M 9% /boot
/dev/mapper/eventhorizon-home 2.0G 153M 1.8G 8% /home
/dev/mapper/eventhorizon-tmp 368M 11M 339M 3% /tmp
/dev/mapper/eventhorizon-backups 39G 176M 37G 1% /backups
/dev/mapper/eventhorizon-var 2.8G 181M 2.5G 7% /var

Great! all is as expected.
Now i can install and configure Bareos, so follow my next posts!!
Giuseppe

Welcome Twentytherteen, just add a sidebar and show excerpt|summary in home, search and co.

twentytherteen-screenshotI just installed and enabled this new theme Twentytherteen, very nice, clean and with this VERY BIG font that is fancy nowadays.

Only two remarks:

In order to make the theme shows the summaries in place of the full articles in Home page and other similar circumstances (search results, author page, tag page, archive page, home page) , just find and edit the file called content.php in the root folder of your theme. Easy to do with the theme editor of Word Press. And look for the following line

<?php if ( is_search() ) : // Only display Excerpts for Search ?>

And replace it with this one, and feel free to remove the pages were you want to show the full article instead (It’s very intuitive)

<?php if ( is_search() || is_author() ||  is_tag() ||  is_archive()  || is_home () ) : // Only display Excerpts for Search ?>

This was about showing excerpts in home, search and other pages with TwentyTherteen.

Now let’s see how to make the sidebar  work back. Easier than expected inf act in TwentyTherteen the main sidebar will appear at the bottom of the pages, while the secondary sidebar will appear as sidebar. Just move stuff from the first to the second and your sidebar will be back in place before you can say “blueberry pie”.

Ciao!