原文地址::http://stackoverflow.com/questions/646930/cannot-connect-to-x-server-0-0-with-a-qt-application

相关文章

1、cannot connect to X server :0.0  ----http://rrewwe.blog.163.com/blog/static/9946464200952595753555/

2、Cannot connect to X server :0.0 as superuser----http://unix.stackexchange.com/questions/111831/cannot-connect-to-x-server-0-0-as-superuser

24down votefavorite

11

Compiling on Fedora 10.

I have just started my first qt GUI application. I used all the default settings.

Its just a simple form. It builds OK without any errors. But when I try and run the application. I get the following message:

Starting /home/rob/projects/qt/test1/test1/test1...
No protocol specified
test1: cannot connect to X server :0.0

Thanks for any advice,

The general causes for this are as follows:

  1. DISPLAY not set in the environment.
    Solution:

    export DISPLAY=:0.0
    ./myQtCmdHere

    ( This one doesn't appear to be the one at fault though, as its saying which X display its trying to connect to. Also, its not always 0.0, but most of the time it is )

  2. Non-Authorised User trying to run the X Application
    Solution ( as X owning user, ie: yourself )

    xhost +local:root   # where root is the local user you want to grant access to.
24down votefavorite

11

Compiling on Fedora 10.

I have just started my first qt GUI application. I used all the default settings.

Its just a simple form. It builds OK without any errors. But when I try and run the application. I get the following message:

Starting /home/rob/projects/qt/test1/test1/test1...
No protocol specified
test1: cannot connect to X server :0.0

Thanks for any advice,

cannot connect to X server :0.0相关推荐

  1. 解决 wsl Cannot Connect to X display 和 Message bochs cannot connect to X server localhost0.0

    解决 Cannot Connect to X display Message bochs cannot connect to X server localhost0.0 真象还原当时是这个报错 Eve ...

  2. MariaDB: ERROR 2003 (HY000): Can't connect to MySQL server on '127.0.0.1' (111 Connection refused)

    MariaDB : ERROR 2003 (HY000): Can't connect to MySQL server on '127.0.0.1' (111 "Connection ref ...

  3. mysqldump: Got error: 2003: Can't connect to MySQL server on '127.0.0.1' (10060)

    今天在用批处理进行MySQL自动备份的过程中遇到一个问题,错误提示:mysqldump: Got error: 2003: Can't connect to mysql server on '127. ...

  4. couldn't connect to server 127.0.0.1:27017 src/mongo/

    couldn't connect to server 127.0.0.1:27017 src/mongo/ 一般这种情况就是:自己指定的数据库,所以不能.自动加载服务.第二次就不能连接了 每次启动前, ...

  5. error: couldn't connect to server 127.0.0.1:27017 src/mongo/shell/mongo.js

    error: couldn't connect to server 127.0.0.1:27017 src/mongo/shell/mongo.js 一般这种情况就是:自己指定的数据库,所以不能.自动 ...

  6. MySql error 2003 Can't connect to MySQL server on 'localhost' (0)

    事情是这样的,今天群里一个小伙伴使用MySql的时候出现了error 2003 Can't connect to MySQL server on 'localhost' (0).见下图. 我们来分析, ...

  7. 【mongodb】couldn't connect to server 127.0.0.1:27017 (127.0.0.1)

    couldn't connect to server 127.0.0.1:27017 (127.0.0.1), connection attempt failed at src/mongo/shell ...

  8. 解决MySQL workbench的Can‘t connect to MySQL server on ‘127.0.0.1‘(10061)问题

    解决MySQL workbench的Can't connect to MySQL server on '127.0.0.1'(10061)问题 参考文章: (1)解决MySQL workbench的C ...

  9. Mac Navicat连接MySQL8.0.11出错:2003 - Can't connect to MySQL server on ……(61 Connection refused)

    MySQL8.0.11处于空密码情况下,Navicat for MySQL连接MySQL会出现以下提示: 2003 - Can't connect to MySQL server on '127.0. ...

  10. MySql - “Can‘t connect to MySQL server on ‘127.0.0.1‘ ([Errno 61] Connection refused)“

    之前用 PyMySql 模组连结本地端的 MySQL 工作的挺顺利的,谁知道在 Mac 重开机后资料库连不上了,报错讯息如下: "Can't connect to MySQL server ...

最新文章

  1. “Linux频道”有链接打不开
  2. 一文透彻详解卡尔曼滤波原理
  3. APUE(第三章)文件IO
  4. 深入理解阿里分布式消息中间件
  5. 图文讲解5G调制,特别通俗易懂!
  6. python 进程 线程 协程
  7. windows服务器新建管理员用户_用户和组管理
  8. HDU 5515 Game of Flying Circus 二分
  9. Spring入门(1)
  10. C语言入门经典(第四版).pdf
  11. psftp的用法(超级详细)
  12. Win制作苹果IOS证书
  13. 51单片机蓝牙模块的使用方法
  14. 第8章 Stata主成分分析与因子分析
  15. C++之个人银行账户管理程序(二)
  16. 从oracle临时表理解会话与链接
  17. 深入浅出理解SVM支持向量机
  18. 基于Python的SAP流程自动化
  19. UVa 12304 2D Geometry 110 in 1!(圆的处理)
  20. 防火墙服务器搭建与应用(1.0)

热门文章

  1. 大数据云计算支撑公安工作跨越发展
  2. 生物信息学之抗癌药物反应论文阅读三:ML+PDX
  3. php判断caj文件页数,CAJ转Word有没有既免费还不限制页数的转换工具?
  4. AopAutoConfiguration matched: - @ConditionalOnProperty (spring.aop.auto=true) matched (OnPrope.
  5. android studio图形验证码,android 一行代码,快速实现图片验证码(附android studio 版小demo)...
  6. IDEA 2019 修改中文字体
  7. Python库——Faker
  8. RxJava Observer与Subscriber的关系
  9. MyEclipse 2016 的破解激活
  10. 什么是服务器、云服务的优缺点是什么、为什么要使用云服务器?