1. Install your application on the server first, if you have media files,
then copy them from your localhost to the server
2. Do the dumpdata from your local in .json, then copy that json to your
server
3. Once on the server just load that json with the loaddata command.

On Mon, Nov 25, 2019 at 2:58 PM Ram <ram.mullap...@gmail.com> wrote:

> Hi Carlos,
>
> I see there is a typo in my previous steps which could have mislead you.
> Basically old and new sites are different databases. Old site is running
> remotely in local host on our Developer's machine with MySQL dB. Now I've
> setup new hosting server with Postgres database (empty site so far) in a
> Digital Ocean's droplet ( Ubuntu 18.04 OS).  So what I'm planning now is I
> will not run these commands in new server's virtual environment
>
> 4.1.    (virtual env) ~/myprojectdir/manage.py makemigrations
> 4.2. (virtual env) ~/myprojectdir/manage.py migrate
> 4.3. (virtual env) ~/myprojectdir/manage.py collectstatic
>
> Before running the above, I will run all 'Migrating a Django app from
> MySQL to PostgreSQL' steps documented in your blog first and then proceed
> with the above commands in my server virtual environment.
>
> I believe I've to run your steps in virtual environment only right?
>
> Thanks,
> ~Ram
>
>
> On Mon, Nov 25, 2019 at 12:53 PM carlos <crocha09...@gmail.com> wrote:
>
>> i thing is good your plan copy your files local to server
>> then dumpdata in local database and copy to server and last you loaddata
>> in your server
>>
>> cheers
>>
>> On Sat, Nov 23, 2019 at 10:13 PM Mohammad yunus <yunus...@gmail.com>
>> wrote:
>>
>>> Is this "migration" command will work for all type of databases or just
>>> only for sqllite3?
>>>
>>> On Sun, 24 Nov 2019, 9:12 am Ram, <ram.mullap...@gmail.com> wrote:
>>>
>>>> Hi Carlos,
>>>>
>>>> If you get to see my email, could you review my plan and let me know
>>>> whether my plan works for migration.
>>>>
>>>> 1. I have setup new Ubuntu 18.04 server in Digital Ocean droplet
>>>> 2. Installed Postgress, Django with default settings and empty site,
>>>> which means I did not bring/copy over the my Django project files yet
>>>> 3. My next step is to copy over all the Django project files which are
>>>> located in my developer's localhost
>>>> 4. Once the files are copied to project folder in this new server I
>>>> will have to run following commands, but I will not run these because old
>>>> and new sites have same database software.
>>>> 4.1.    (virtual env) ~/myprojectdir/manage.py makemigrations
>>>> 4.2. (virtual env) ~/myprojectdir/manage.py migrate
>>>> 4.3. (virtual env) ~/myprojectdir/manage.py collectstatic
>>>>
>>>> 5. So I want to start with your steps pointed in your blog
>>>> <https://www.calazan.com/migrating-django-app-from-mysql-to-postgresql/>
>>>> since I have to start with an empty Postgres database. I'm not sure whether
>>>> this will work or not.
>>>> 6. Hopefully if all the commands are successful, I will run the above
>>>> commands.
>>>>
>>>> Please let me know if my plan generally would work? I know you don't
>>>> have complete picture, but I'm wondering if you have any thoughts about my
>>>> use case?
>>>>
>>>> Thanks,
>>>> ~Ram
>>>>
>>>>
>>>>
>>>>
>>>> On Sat, Nov 23, 2019 at 4:32 PM Ram <ram.mullap...@gmail.com> wrote:
>>>>
>>>>> Hello Carlos,
>>>>>
>>>>> The steps looks promising. We will try it and let you know.
>>>>>
>>>>> Our dB is originally from MySQL configured for PHP based website and
>>>>> later on we moved to Django project development. Now we planned to migrate
>>>>> the site to Postgres database running on Ubuntu for Django project.
>>>>>
>>>>> Thank you very much.,
>>>>> ~Ram
>>>>>
>>>>> On Sat, Nov 23, 2019 at 4:01 PM carlos <crocha09...@gmail.com> wrote:
>>>>>
>>>>>> maybe this link help you!
>>>>>> https://www.calazan.com/migrating-django-app-from-mysql-to-postgresql/
>>>>>>
>>>>>> On Sat, Nov 23, 2019 at 12:23 PM Ram <ram.mullap...@gmail.com> wrote:
>>>>>>
>>>>>>> Hi,
>>>>>>>
>>>>>>> We have our Django based website running in our local windows box
>>>>>>> with MySQL database. We plan to deploy our site on Ubuntu, Postgress,
>>>>>>> Gunicorn and Nginx stack server. I'm looking for a way to achieve this 
>>>>>>> even
>>>>>>> with the manual intervention? I appreciate if someone can point me the
>>>>>>> right direction with appropriate documentation.
>>>>>>>
>>>>>>> Thank,
>>>>>>> ~Ram
>>>>>>>
>>>>>>> --
>>>>>>> You received this message because you are subscribed to the Google
>>>>>>> Groups "Django users" group.
>>>>>>> To unsubscribe from this group and stop receiving emails from it,
>>>>>>> send an email to django-users+unsubscr...@googlegroups.com.
>>>>>>> To view this discussion on the web visit
>>>>>>> https://groups.google.com/d/msgid/django-users/CA%2BOi5F1mHwkiidgcUgFJDR0e9MGbJj%2BJTZWfKgVjXkS-uN9kEw%40mail.gmail.com
>>>>>>> <https://groups.google.com/d/msgid/django-users/CA%2BOi5F1mHwkiidgcUgFJDR0e9MGbJj%2BJTZWfKgVjXkS-uN9kEw%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>>>>>> .
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> att.
>>>>>> Carlos Rocha
>>>>>>
>>>>>> --
>>>>>> You received this message because you are subscribed to the Google
>>>>>> Groups "Django users" group.
>>>>>> To unsubscribe from this group and stop receiving emails from it,
>>>>>> send an email to django-users+unsubscr...@googlegroups.com.
>>>>>> To view this discussion on the web visit
>>>>>> https://groups.google.com/d/msgid/django-users/CAM-7rO2Dm031aVT21qWyh_1nHSGUpzj3vYxZsXaN_Y1nTGppOw%40mail.gmail.com
>>>>>> <https://groups.google.com/d/msgid/django-users/CAM-7rO2Dm031aVT21qWyh_1nHSGUpzj3vYxZsXaN_Y1nTGppOw%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>>>>> .
>>>>>>
>>>>> --
>>>> You received this message because you are subscribed to the Google
>>>> Groups "Django users" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send
>>>> an email to django-users+unsubscr...@googlegroups.com.
>>>> To view this discussion on the web visit
>>>> https://groups.google.com/d/msgid/django-users/CA%2BOi5F1F3_sSVXm1igaP%3DTAKv-2kf0Ux6bXWvCKaQs0HZr_Yvg%40mail.gmail.com
>>>> <https://groups.google.com/d/msgid/django-users/CA%2BOi5F1F3_sSVXm1igaP%3DTAKv-2kf0Ux6bXWvCKaQs0HZr_Yvg%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>>> .
>>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Django users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to django-users+unsubscr...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/CAEQiGcM8cW%3DOjkKjk2quBThXUGQNQDkKvFumn_%2BxvQBJPJnnsg%40mail.gmail.com
>>> <https://groups.google.com/d/msgid/django-users/CAEQiGcM8cW%3DOjkKjk2quBThXUGQNQDkKvFumn_%2BxvQBJPJnnsg%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>> .
>>>
>>
>>
>> --
>> att.
>> Carlos Rocha
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to django-users+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CAM-7rO1Z5mjXcX3rAL9s7ZvMoUvr1mMVGZO1nismOcmZmM2F8Q%40mail.gmail.com
>> <https://groups.google.com/d/msgid/django-users/CAM-7rO1Z5mjXcX3rAL9s7ZvMoUvr1mMVGZO1nismOcmZmM2F8Q%40mail.gmail.com?utm_medium=email&utm_source=footer>
>> .
>>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CA%2BOi5F280BiS3HrFHf2isMq3HPX7esFSJe6ow-Kv14k9KPjwTg%40mail.gmail.com
> <https://groups.google.com/d/msgid/django-users/CA%2BOi5F280BiS3HrFHf2isMq3HPX7esFSJe6ow-Kv14k9KPjwTg%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
>


-- 
att.
Carlos Rocha

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAM-7rO1qZ3KY%2BBNerPmEyBEC8N7ecEt31yqhvjXcxneFtU9-FA%40mail.gmail.com.

Reply via email to