Enabling PDO for CLI in vagrant box precise64 (Ubuntu server 12.04 LTS)getting PHP PDO flavors to work on Mac...

Unreachable code, but reachable with exception

2D counterpart of std::array in C++17

Why do passenger jet manufacturers design their planes with stall prevention systems?

Can hydraulic brake levers get hot when brakes overheat?

Official degrees of earth’s rotation per day

How could a scammer know the apps on my phone / iTunes account?

Why doesn't the EU now just force the UK to choose between referendum and no-deal?

How to generate globally unique ids for different tables of the same database?

Make a transparent 448*448 image

Professor being mistaken for a grad student

Is it possible that AIC = BIC?

Does this property of comaximal ideals always holds?

At what level can a dragon innately cast its spells?

Provisioning profile doesn't include the application-identifier and keychain-access-groups entitlements

Does this AnyDice function accurately calculate the number of ogres you make unconcious with three 4th-level castings of Sleep?

What are the possible solutions of the given equation?

Is it possible to upcast ritual spells?

What is the greatest age difference between a married couple in Tanach?

My adviser wants to be the first author

Is a lawful good "antagonist" effective?

How can I change step-down my variable input voltage? [Microcontroller]

Can elves maintain concentration in a trance?

Is having access to past exams cheating and, if yes, could it be proven just by a good grade?

When do we add an hyphen (-) to a complex adjective word?



Enabling PDO for CLI in vagrant box precise64 (Ubuntu server 12.04 LTS)


getting PHP PDO flavors to work on Mac OS XTrying to install pdo_oci via PECL fails asking for PDO extensionPublic static ip for vagrant boxInstall php 5.3.10 in ubuntu 12.04how can I install PHP5 manually on UbuntuSecuring PHP on Ubuntu 12.04 LTS?Weird network problems with Vagrant, VirtualBox, Ansible and Ubuntu Server boxUbuntu Server 12.04: upgraded php to 5.4, now sites won't loadApache 2.4 & Ubuntu 14.04 error on Vagrant: “You don't have permission to access / on this server.”How to solve “The apache2 configtest failed.” in ubuntu 12.04 lts













0















I have vagrant box (precise64) utilizing Ubuntu server 12.04.
I have installed manually (no use of LAMP) on the server the following:




  • MySql server / MySql client - Server version: 5.5.31-0ubuntu0.12.04.1 (Ubuntu)

  • PHP5 - PHP 5.3.10-1ubuntu3.6 with Suhosin-Patch (cli) (built: Mar 11 2013 14:31:48)

  • Apache2 - Server version: Apache/2.2.22 (Ubuntu) (was already existing on the box)


On the host (my desktop) I've set vagrant file and shared folders, installed CakePHP and I'm able to see the main page. (after setting VirtualHost on the server of course).



I've connected to the database with no problem.
When I try to use a CLI tool of CakePHP I get the following error:



Error: Database connection "Mysql" is missing, or could not be created


I've also created a post regarding this matter on StackOverflow but decided to see if it's might be a server miss-configuration issue.



I've made sure PDO is enabled by the following results:



vagrant@precise64:/etc/php5/conf.d$ php -i | grep PDO
PDO
PDO support => enabled
PDO drivers => mysql
PDO Driver for MySQL => enabled


Since the answer was given to me on SO was to make sure PDO is enabled for the cli.



I've tested using vanilla PHP and was able to connect to my database using PDO.
Yet I'm still unable to figure what causing this problem.
Any help would be greatly appreciated.










share|improve this question
















bumped to the homepage by Community 7 mins ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.




















    0















    I have vagrant box (precise64) utilizing Ubuntu server 12.04.
    I have installed manually (no use of LAMP) on the server the following:




    • MySql server / MySql client - Server version: 5.5.31-0ubuntu0.12.04.1 (Ubuntu)

    • PHP5 - PHP 5.3.10-1ubuntu3.6 with Suhosin-Patch (cli) (built: Mar 11 2013 14:31:48)

    • Apache2 - Server version: Apache/2.2.22 (Ubuntu) (was already existing on the box)


    On the host (my desktop) I've set vagrant file and shared folders, installed CakePHP and I'm able to see the main page. (after setting VirtualHost on the server of course).



    I've connected to the database with no problem.
    When I try to use a CLI tool of CakePHP I get the following error:



    Error: Database connection "Mysql" is missing, or could not be created


    I've also created a post regarding this matter on StackOverflow but decided to see if it's might be a server miss-configuration issue.



    I've made sure PDO is enabled by the following results:



    vagrant@precise64:/etc/php5/conf.d$ php -i | grep PDO
    PDO
    PDO support => enabled
    PDO drivers => mysql
    PDO Driver for MySQL => enabled


    Since the answer was given to me on SO was to make sure PDO is enabled for the cli.



    I've tested using vanilla PHP and was able to connect to my database using PDO.
    Yet I'm still unable to figure what causing this problem.
    Any help would be greatly appreciated.










    share|improve this question
















    bumped to the homepage by Community 7 mins ago


    This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.


















      0












      0








      0








      I have vagrant box (precise64) utilizing Ubuntu server 12.04.
      I have installed manually (no use of LAMP) on the server the following:




      • MySql server / MySql client - Server version: 5.5.31-0ubuntu0.12.04.1 (Ubuntu)

      • PHP5 - PHP 5.3.10-1ubuntu3.6 with Suhosin-Patch (cli) (built: Mar 11 2013 14:31:48)

      • Apache2 - Server version: Apache/2.2.22 (Ubuntu) (was already existing on the box)


      On the host (my desktop) I've set vagrant file and shared folders, installed CakePHP and I'm able to see the main page. (after setting VirtualHost on the server of course).



      I've connected to the database with no problem.
      When I try to use a CLI tool of CakePHP I get the following error:



      Error: Database connection "Mysql" is missing, or could not be created


      I've also created a post regarding this matter on StackOverflow but decided to see if it's might be a server miss-configuration issue.



      I've made sure PDO is enabled by the following results:



      vagrant@precise64:/etc/php5/conf.d$ php -i | grep PDO
      PDO
      PDO support => enabled
      PDO drivers => mysql
      PDO Driver for MySQL => enabled


      Since the answer was given to me on SO was to make sure PDO is enabled for the cli.



      I've tested using vanilla PHP and was able to connect to my database using PDO.
      Yet I'm still unable to figure what causing this problem.
      Any help would be greatly appreciated.










      share|improve this question
















      I have vagrant box (precise64) utilizing Ubuntu server 12.04.
      I have installed manually (no use of LAMP) on the server the following:




      • MySql server / MySql client - Server version: 5.5.31-0ubuntu0.12.04.1 (Ubuntu)

      • PHP5 - PHP 5.3.10-1ubuntu3.6 with Suhosin-Patch (cli) (built: Mar 11 2013 14:31:48)

      • Apache2 - Server version: Apache/2.2.22 (Ubuntu) (was already existing on the box)


      On the host (my desktop) I've set vagrant file and shared folders, installed CakePHP and I'm able to see the main page. (after setting VirtualHost on the server of course).



      I've connected to the database with no problem.
      When I try to use a CLI tool of CakePHP I get the following error:



      Error: Database connection "Mysql" is missing, or could not be created


      I've also created a post regarding this matter on StackOverflow but decided to see if it's might be a server miss-configuration issue.



      I've made sure PDO is enabled by the following results:



      vagrant@precise64:/etc/php5/conf.d$ php -i | grep PDO
      PDO
      PDO support => enabled
      PDO drivers => mysql
      PDO Driver for MySQL => enabled


      Since the answer was given to me on SO was to make sure PDO is enabled for the cli.



      I've tested using vanilla PHP and was able to connect to my database using PDO.
      Yet I'm still unable to figure what causing this problem.
      Any help would be greatly appreciated.







      php5 ubuntu-12.04 vagrant pdo






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited May 23 '17 at 11:33









      Community

      1




      1










      asked May 23 '13 at 11:45









      Shahar GalukmanShahar Galukman

      1571211




      1571211





      bumped to the homepage by Community 7 mins ago


      This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.







      bumped to the homepage by Community 7 mins ago


      This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
























          1 Answer
          1






          active

          oldest

          votes


















          0














          PDO was enabled on the guest (server) side while I tried to use the CLI on the HOST (Desktop) side.
          Using the CLI from the guest work with no problem (I guess setting PDO enabled on HOST might do the trick also, not sure of that though)






          share|improve this answer























            Your Answer








            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "2"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














            draft saved

            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f510212%2fenabling-pdo-for-cli-in-vagrant-box-precise64-ubuntu-server-12-04-lts%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            PDO was enabled on the guest (server) side while I tried to use the CLI on the HOST (Desktop) side.
            Using the CLI from the guest work with no problem (I guess setting PDO enabled on HOST might do the trick also, not sure of that though)






            share|improve this answer




























              0














              PDO was enabled on the guest (server) side while I tried to use the CLI on the HOST (Desktop) side.
              Using the CLI from the guest work with no problem (I guess setting PDO enabled on HOST might do the trick also, not sure of that though)






              share|improve this answer


























                0












                0








                0







                PDO was enabled on the guest (server) side while I tried to use the CLI on the HOST (Desktop) side.
                Using the CLI from the guest work with no problem (I guess setting PDO enabled on HOST might do the trick also, not sure of that though)






                share|improve this answer













                PDO was enabled on the guest (server) side while I tried to use the CLI on the HOST (Desktop) side.
                Using the CLI from the guest work with no problem (I guess setting PDO enabled on HOST might do the trick also, not sure of that though)







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered May 24 '13 at 11:53









                Shahar GalukmanShahar Galukman

                1571211




                1571211






























                    draft saved

                    draft discarded




















































                    Thanks for contributing an answer to Server Fault!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f510212%2fenabling-pdo-for-cli-in-vagrant-box-precise64-ubuntu-server-12-04-lts%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Фонтен-ла-Гаярд Зміст Демографія | Економіка | Посилання |...

                    Список ссавців Італії Природоохоронні статуси | Список |...

                    Маріан Котлеба Зміст Життєпис | Політичні погляди |...