# How can I use MySQL 8.0 on Xenial Distribution, currently it says 5.7

**URL:** <https://travis-ci.community/t/how-can-i-use-mysql-8-0-on-xenial-distribution-currently-it-says-5-7/2728>\
**Category:** Travis CI Discussions & Feedback\
**Created:** [March 20, 2019, 4:11pm UTC](https://travis-ci.community/t/how-can-i-use-mysql-8-0-on-xenial-distribution-currently-it-says-5-7/2728 "2019-03-20T16:11:51Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![akki-io](https://avatars.discourse-cdn.com/v4/letter/a/7feea3/32.png) [@akki-io](https://travis-ci.community/u/akki-io)\
**Post date:** [March 20, 2019, 4:11pm UTC](https://travis-ci.community/t/how-can-i-use-mysql-8-0-on-xenial-distribution-currently-it-says-5-7/2728/1 "2019-03-20T16:11:51Z")

</div>

I am trying to upgrade MySQL to 8.0 from 5.7 on Xenial Distribution. I have no idea where to start. I referred the docs and didn’t find any documentation on how to do so.

Any idea?

---

<div class="post-metadata">

**Author:** ![akki-io](https://avatars.discourse-cdn.com/v4/letter/a/7feea3/32.png) [@akki-io](https://travis-ci.community/u/akki-io)\
**Post date:** [March 21, 2019, 4:09pm UTC](https://travis-ci.community/t/how-can-i-use-mysql-8-0-on-xenial-distribution-currently-it-says-5-7/2728/2 "2019-03-21T16:09:06Z")

</div>

I was finally able to use MySQL 8.0, this is how I am currently using it. This works for now. But if someone has a better way let me know.

```
dist: xenial

sudo: true

language: php

services:
  - mysql

php:
  - "7.2"

before_script:
  - wget https://repo.mysql.com//mysql-apt-config_0.8.10-1_all.deb
  - sudo dpkg -i mysql-apt-config_0.8.10-1_all.deb
  - sudo apt-get update -q
  - sudo apt-get install -q -y --allow-unauthenticated -o Dpkg::Options::=--force-confnew mysql-server
  - sudo systemctl restart mysql
  - sudo mysql_upgrade
  - mysql --version  

script:
  - ./vendor/bin/phpunit
```

---

<div class="post-metadata">

**Author:** ![andrerom](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/andrerom/32/1432_2.png) [@andrerom](https://travis-ci.community/u/andrerom)\
**Post date:** [March 22, 2019, 6:58pm UTC](https://travis-ci.community/t/how-can-i-use-mysql-8-0-on-xenial-distribution-currently-it-says-5-7/2728/3 "2019-03-22T18:58:24Z")

</div>

Nice,

was about to try to do the same.  
Seems btw there is a new .deb file out: [https://dev.mysql.com/downloads/repo/apt/](https://dev.mysql.com/downloads/repo/apt/)

@BanzaiMan is this something that could go into doc?

---

<div class="post-metadata">

**Author:** ![RonDen](https://avatars.discourse-cdn.com/v4/letter/r/7993a0/32.png) [@RonDen](https://travis-ci.community/u/RonDen)\
**Post date:** [May 9, 2019, 6:49am UTC](https://travis-ci.community/t/how-can-i-use-mysql-8-0-on-xenial-distribution-currently-it-says-5-7/2728/4 "2019-05-09T06:49:14Z")

</div>

what is the meaning of this command `sudo apt-get install -q -y --allow-unauthenticated -o Dpkg::Options::=--force-confnew mysql-server`
