# WSS Issue VPBX 4 Fresh Install

**URL:** <https://forums.vitalpbx.org/t/wss-issue-vpbx-4-fresh-install/4232>\
**Category:** VitalPBX 4\
**Created:** [July 3, 2024, 12:54am UTC](https://forums.vitalpbx.org/t/wss-issue-vpbx-4-fresh-install/4232 "2024-07-03T00:54:07Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![mohamed.soliman](https://forums.vitalpbx.org/letter_avatar_proxy/v4/letter/m/85e7bf/32.png) [@mohamed.soliman](https://forums.vitalpbx.org/u/mohamed.soliman)\
**Post date:** [July 3, 2024, 12:54am UTC](https://forums.vitalpbx.org/t/wss-issue-vpbx-4-fresh-install/4232/1 "2024-07-03T00:54:07Z")

</div>

After fresh install Vitalpbx v4 several times , and installing Vitxi ,  
The error occured

##### The connection to your server could not be established.

Please, contact the administrator.

and after tracing the problem :

- Port 6001 , 8089 ,3500-3501 443 is open on the firewall and reachable
- when accessing [https://FQDN:8089/ws](https://FQDN:8089/ws) opens and get upgrade required
- SSL Certificate issued from letsencrypt and vaild
- PJSIP Profile is correct and configured

But no luck the vitix don’t load  
we also open the browser console . and get this message  
**Waterfox can’t establish a connection to the server at wss://FQDN:6001/app/vitxi4561aq/console.**

When tried to run the command thats correct ssl  
**root@vitalpbx:~# /usr/share/vitxi/backend/artisan websockets:ssl-config**  
**/usr/bin/env: ‘php\r’: No such file or directory**

also we checked /usr/share/vitxi/backend/.env we found thats the section of the  
LARAVEL\_WEBSOCKETS\_SSL\_LOCAL\_CERT=  
LARAVEL\_WEBSOCKETS\_SSL\_LOCAL\_PK=  
LARAVEL\_WEBSOCKETS\_SSL\_PASSPHRASE=  
is Empty

This is fatal issue , kindly support asap ,

Regards Mohamed Soliman

---

<div class="post-metadata">

**Author:** ![EINM](https://forums.vitalpbx.org/user_avatar/forums.vitalpbx.org/einm/32/375_2.png) [@EINM](https://forums.vitalpbx.org/u/EINM)\
**Post date:** [July 3, 2024, 4:44am UTC](https://forums.vitalpbx.org/t/wss-issue-vpbx-4-fresh-install/4232/2 "2024-07-03T04:44:42Z")

</div>

Try the below to fix the newline (from [stackoverflow](https://stackoverflow.com/questions/2613800/how-to-convert-dos-windows-newline-crlf-to-unix-newline-lf))

```auto
cd /usr/share/vitxi/backend
tr -d '\015' <artisan >artisan.new
mv artisan artisan.old
mv artisan.new artisan
chmod +x artisan
chown www-data:www-data artisan

```

Then run `/usr/share/vitxi/backend/artisan websockets:ssl-config` again.

---

<div class="post-metadata">

**Author:** ![sama](https://forums.vitalpbx.org/letter_avatar_proxy/v4/letter/s/7993a0/32.png) [@sama](https://forums.vitalpbx.org/u/sama)\
**Post date:** [July 4, 2024, 4:12am UTC](https://forums.vitalpbx.org/t/wss-issue-vpbx-4-fresh-install/4232/3 "2024-07-04T04:12:49Z")

</div>

You can also install dos2unix `apt install dos2unix` and run

> dos2unix /usr/share/vitxi/backend/artisan
