Error unable to initialize gtk is display set properly

If you have an error that gtk cannot be initialized, filezilla is correctly configured on your machine, then this user guide will hopefully help you solve the problem.     I have configured Filezilla on Ubuntu and I need to rush from the command line. But when I try to run it, it shows...

Skip to content

Windows Diary

If you have an error that gtk cannot be initialized, filezilla is correctly configured on your machine, then this user guide will hopefully help you solve the problem.

Approved: ASR Pro

  • 1. Download ASR Pro and install it on your computer
  • 2. Launch the program and click «Scan»
  • 3. Click «Repair» to fix any issues that are found
  • Speed up your computer’s performance now with this simple download.

    I have configured Filezilla on Ubuntu and I need to rush from the command line. But when I try to run it, it shows eg. I get the app or version:

      ~ $ filezilla -hError: gtk could not be initialized, is DISPLAY correct?~ $ filezilla -vError: gtk cannot be initialized, almost certainly is DISPLAY set correctly? 
    1. Error: Gtk Could Not Be Initialized, Is DISPLAY Set Correctly? [/ Coded]

      I downloaded FileZilla_3.0.11_x86_64-linux-gnu.tar.bz2.

      Approved: ASR Pro

      ASR Pro is the world’s most popular and effective PC repair tool. It is trusted by millions of people to keep their systems running fast, smooth, and error-free. With its simple user interface and powerful scanning engine, ASR Pro quickly finds and fixes a broad range of Windows problems — from system instability and security issues to memory management and performance bottlenecks.

    2. 1. Download ASR Pro and install it on your computer
    3. 2. Launch the program and click «Scan»
    4. 3. Click «Repair» to fix any issues that are found

    Code:

     root @ AL-Linux: / opt # and tar-rest -jxf FileZilla_3.0.11_x86_64-linux-gnu.tar.bz2root @ AL-Linux: / opt # cd FileZilla3 / binroot @ AL-Linux: / opt / FileZilla3 / bin # ./filezillaError: Gtk could not be initialized, is the DISPLAY parameter displayed correctly? 

    Are there any ways to make FileZilla work?

    thanks a lot

    error unable to initialize gtk is display set properly filezilla

    Ubuntu 12.06 x86_64 Intel • Core 2 Quad Q6600 2.4 GHz 8 MB cache 1066 MHz Intel MoBo DG33
    8 GB DDR2 800 MHz RAM • nVidia 8600 GT 1 GB graphics card • Dell SP2309W • LG Flatron L222WS

  • Subject: Error: Unable To Initialize Successfully. Gtk, Is The DISPLAY Correct? [/ Coded]

    At this point, is there a reason why you cannot use Filezilla in the repositories? It is least available for the 32-bit version. To buy:

    Code:

     sudo apt-get install try filezilla 

    Don’t let anything “fast” until you can quantify “slow”.

  • Subject: Error: Gtk Could Not Be Initialized, DISPLAY Set Up Correctly? [/ Coded]

    1. Didn’t find out that adding / removing FileZilla was stopped – this is dosstupid only if you select “Exclude all open source applications” and select “Supported applications”. I just added it here and FileZilla 3.07.1_x86_64 transcription is installed and working.
    error unable to initialize gtk is display set properly filezilla

    2. Why did the previous command shell still not work?

    Ubuntu 12.06 x86_64 Intel • Core 2 Quad Q6600 2.4 GHz 8 MB cache 1066 MHz Intel MoBo DG33
    8GB DDR2 800MHz RAM • 1GB nVidia GT 8600 graphics card • Dell SP2309W • LG Flatron L222WS

  • Subject: Error: Unable To Initialize Gtk, Is DISPLAY Installed Correctly? [/ Coded]

    Looking at the original message, it looks like the person executed “sudo -i” before trying to start the application. The parent shell variables (including $ DISPLAY) were placed here, so the application couldn’t start because it didn’t know where to display them.

    Don’t try to do anything until you learn “slow”, until you learn “slow”.

  • Subject: Error: Gtk Cannot Beinitialized, Is DISPLAY Set Correctly? [/ Coded]

    Impressive! Many thanks.
    I just logged out of root and returned to normal user mode and it was running services!

    It’s strange – so if I wanted to launch a root in the market …?

    Ubuntu 12.06 x86_64 Intel • Core 2 Quad Q6600 2.4 GHz 8 MB cache 1066 MHz Intel MoBo DG33
    8 GB DDR2 800 MHz RAM • nVidia 8600 GT 1 GB graphics card • Dell SP2309W • LG Flatron L222WS

  • Subject: Error: Is DISPLAY Set Correctly To Initialize Gtk At Position? [/ Coded]

    Author: anjanesh

    Strange – so if I wanted to work as root …?

    I probably wouldn’t do anything because it is not strictly necessary. Among other things, a common problem is creating dot files in your home directory that will be owned by the root user after running the application’s GUI as root, and this can give strange answers that are difficult to diagnose.

    Don’t try to do anything until you are “fast” to quantify “slow”. Impossible

  • Error: Is DISPLAY Correctly Defined To Initialize Gtk? [/ Encoded]

    Ubuntu 12.06 x86_64 Intel • Core 2 Quad Q6600 2.4 GHz 8 MB cache 1066 MHz Intel MoBo DG33
    RAM 8 GB DDR2 @ • 800 MHz 8600 GT nVidia Graphics Card • Dell SP2309W • LG Flatron L222WS

    I downloaded FileZilla_3.0.11_x86_64-linux-gnu.tar.bz2.

    Code:

     root @ AL-Linux: / opt # and black -jxf FileZilla_3.0.11_x86_64-linux-gnu.tar.bz2root @ AL-Linux: / opt # cd FileZilla3 / binroot @ AL-Linux: / opt / FileZilla3 / bin # .Unable / filezillaerror: is DISPLAY configured correctly to initialize gtk? 

    Any exercises on how to get FileZilla to work?

    thanks a lot

     root @ AL-Linux: / opt # tar-rest -jxf FileZilla_3.0.11_x86_64-linux-gnu.tar.bz2root @ AL-Linux: / opt # cd FileZilla3 / binroot @ AL-Linux: / opt / FileZilla3 / bin # ./filezillaError: unable to initialize gtk, DISPLAY set correctly? 

    Subject: Error: Unable To Initialize Gtk, Is DISPLAY Ready Correctly? [/ Coded]

    Don’t tryIf you want to get something “fast” right, you can quantify “slow”.

    Are there many reasons why you cannot use Filezilla outside of the repositories? It is available for at least 32 bits. To buy:

    error unable to initialize gtk is display set properly filezilla

    Code:

     sudo apt-get install filezilla 
     sudo apt-get create filezilla 

    Subject: Error: Gtk Could Not Be Initialized, DISPLAY Was Always Configured Correctly? [/ Coded]

    Ubuntu 12.06 x86_64 Intel • Core 2 Quad Q6600 2.4 GHz 8 MB cache 1066 MHz Intel MoBo DG33
    RAM 8 GB DDR2 800 MHz • Dell nVidia 8600 GT 1 GB graphics card • SP2309W • LG Flatron L222WS

    1. Didn’t know FileZilla add / remove is complete – it is only available if you are not using all open source and supported apps. I just added it now and the installed version of FileZilla 3.07.1_x86_64 works.

    2. Why didn’t the previous shell command use it?

    Subject: Error: Gtk Could Not Be Initialized, Is DISPLAY Set Correctly Without Prompting? [/ Coded]

    Nottry to do something “fast” until you can quantify “slow”.

    If you look at the original message, it looks like you are in front of “sudo -i” when you try to start the application. In this case, the parent shell components (including $ DISPLAY) were dropped, which prevented the smartphone app from starting as it didn’t know where to display it.

    Subject: Error: gtk cannot initialize, adjust computer screen p

    Speed up your computer’s performance now with this simple download.

    Forum rules
    Topics in this forum are automatically closed 6 months after creation.

    Matthew_Wai

    Level 4
    Level 4
    Posts: 454
    Joined: Sun Jun 07, 2015 10:42 am
    Location: China

    [Solved] System service “Error: Unable to initialize GTK+, is DISPLAY set properly?”

    If I manually run /home/matthew/@/Sync/FreeFileSync "/home/matthew/@/Sync/Backup.ffs_batch", it works, but it doesn’t if I run it via the following service:

    Code: Select all

    matthew@matthew-pc:~$ cat /lib/systemd/system/Testing1.service
    [Service]
    ExecStart=/home/matthew/@/Sync/FreeFileSync "/home/matthew/@/Sync/Backup.ffs_batch"
    
    [Install]
    WantedBy=multi-user.target

    The error is shown below:

    Code: Select all

    matthew@matthew-pc:~$ sudo systemctl status Testing1.service
    [sudo] password for matthew: 
    ● Testing1.service
    Loaded: loaded (/lib/systemd/system/Testing1.service; disabled; vendor preset: enabled)
    Active: failed (Result: exit-code) since Tue 2019-07-09 14:14:33 HKT; 1s ago
    Process: 10255 ExecStart=/home/matthew/@/Sync/FreeFileSync /home/matthew/@/Sync/Backup.ffs_batch (code=exited, status=25
    Main PID: 10255 (code=exited, status=255)
    
    Jul 09 14:14:33 matthew-pc systemd[1]: Started Testing1.service.
    Jul 09 14:14:33 matthew-pc FreeFileSync[10255]: 14:14:33: Error: Unable to initialize GTK+, is DISPLAY set properly?
    Jul 09 14:14:33 matthew-pc systemd[1]: Testing1.service: Main process exited, code=exited, status=255/n/a
    Jul 09 14:14:33 matthew-pc systemd[1]: Testing1.service: Failed with result 'exit-code'.

    How should I solve «Error: Unable to initialize GTK+, is DISPLAY set properly?«

    Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 4 times in total.

    Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.

    gm10

    Level 20
    Level 20
    Posts: 10480
    Joined: Thu Jun 21, 2018 5:11 pm

    gm10

    Level 20
    Level 20
    Posts: 10480
    Joined: Thu Jun 21, 2018 5:11 pm

    Matthew_Wai

    Level 4
    Level 4
    Posts: 454
    Joined: Sun Jun 07, 2015 10:42 am
    Location: China

    Re: System service “Error: Unable to initialize GTK+, is DISPLAY set properly?”

    Post

    by Matthew_Wai » Tue Jul 09, 2019 7:20 am

    Code: Select all

    matthew@matthew-pc:~$ cat ~/.config/systemd/user/Testing2.service
    [Service]
    ExecStart=/home/matthew/@/Sync/FreeFileSync "/home/matthew/@/Sync/Backup.ffs_batch"
    
    [Install]
    WantedBy=default.target
    
    matthew@matthew-pc:~$ systemctl --user start Testing2.service
    Failed to start Testing2.service: Unit Testing2.service not found.
    
    

    «Testing2.service» cannot be found. What should I do?

    rene

    Level 20
    Level 20
    Posts: 11403
    Joined: Sun Mar 27, 2016 6:58 pm

    Re: System service “Error: Unable to initialize GTK+, is DISPLAY set properly?”

    Post

    by rene » Tue Jul 09, 2019 11:47 am

    Warning; enabled systemd user units race with or are even generally not post the user’s X display being up. That is, Mathew would need to set DISPLAY manually, if it works at all (which it judging from previous questions by him does, but only by accident).

    When writing a service+applet on this forum a while ago I (before it turned into a D-Bus service outright) therefore elected to use the desktop startup-application route. Sucks, but systemd user services are at the very least on ubuntu and until ubuntu starts supporting a user «up-and-running.target» to depend on not a very good option.

    And I shall (for the last time) note this issue being originally instance N+1 of Matthew having incorrectly layered his mental image w.r.t. user and system context. That scripting around said incorrect mental image might be good enough for an isolated problem instance, but that continuing to do so might not be doing him any favours in the long run.

    Matthew_Wai

    Level 4
    Level 4
    Posts: 454
    Joined: Sun Jun 07, 2015 10:42 am
    Location: China

    Re: System service “Error: Unable to initialize GTK+, is DISPLAY set properly?”

    Post

    by Matthew_Wai » Thu Jul 11, 2019 1:32 am

    I cannot follow it. It is too difficult for a beginner like me. I don’t know what to do.

    rene wrote: ↑

    Tue Jul 09, 2019 11:47 am

    Mathew would need to set DISPLAY manually

    export DISPLAY=:0 does not work. See below:

    Code: Select all

    matthew@pc:~$ echo $DISPLAY
    :0
    matthew@pc:~$ cat /home/matthew/@/Testing2
    #!/bin/bash 
    export DISPLAY=:0 && /home/matthew/@/Sync/FreeFileSync "/home/matthew/@/Sync/Backup.ffs_batch"
    
    matthew@pc:~$ cat /lib/systemd/system/Testing2.service
    [Service]
    ExecStart=/home/matthew/@/Testing2
    
    [Install]
    WantedBy=multi-user.target
    
    matthew@pc:~$ sudo systemctl start Testing2.service
    [sudo] password for matthew: 
    matthew@pc:~$ sudo systemctl status Testing2.service
    ● Testing2.service
       Loaded: loaded (/lib/systemd/system/Testing2.service; disabled; vendor preset
       Active: failed (Result: exit-code) since Thu 2019-07-11 13:17:41 HKT; 2s ago
      Process: 7246 ExecStart=/home/matthew/@/Testing2 (code=exited, status=255)
     Main PID: 7246 (code=exited, status=255)
    
    Jul 11 13:17:41 pc systemd[1]: Started Testing2.service.
    Jul 11 13:17:41 pc Testing2[7246]: No protocol specified
    Jul 11 13:17:41 pc Testing2[7246]: 13:17:41: Error: Unable to initialize GTK+, is DISPLAY set properly?
    Jul 11 13:17:41 pc systemd[1]: Testing2.service: Main process exited, code=exited, status=255/n/a
    Jul 11 13:17:41 pc systemd[1]: Testing2.service: Failed with result 'exit-code'.

    User avatar

    thx-1138

    Level 8
    Level 8
    Posts: 2096
    Joined: Fri Mar 10, 2017 12:15 pm
    Location: Athens, Greece

    Re: System service “Error: Unable to initialize GTK+, is DISPLAY set properly?”

    Post

    by thx-1138 » Thu Jul 11, 2019 4:27 am

    …(completely untested by me)… you could *probably* get around such by adding

    Environment=»DISPLAY=:0″

    in the service file itself, or, if still not enough, maybe…

    Environment=»DISPLAY=:0″ «XAUTHORITY=/home/matthew/.Xauthority»

    I repeat, untested by me.

    But my question is why you complicate it & insist on using systemd in the first place above,
    instead of simply using an autostart entry (.config/autostart/whatever.desktop file)…

    Matthew_Wai

    Level 4
    Level 4
    Posts: 454
    Joined: Sun Jun 07, 2015 10:42 am
    Location: China

    Re: System service “Error: Unable to initialize GTK+, is DISPLAY set properly?”

    Post

    by Matthew_Wai » Fri Jul 12, 2019 1:56 am

    The above convoluted article does not provide the following simple solution:

    thx-1138 wrote: ↑

    Thu Jul 11, 2019 4:27 am

    Environment=»DISPLAY=:0″ «XAUTHORITY=/home/matthew/.Xauthority»

    This one works. Thank you!

    thx-1138 wrote: ↑

    Thu Jul 11, 2019 4:27 am

    But my question is why you complicate it & insist on using systemd in the first place above

    Because I want FreeFileSync to run sudo on completion as shown below:
    <PostSyncCommand Condition="Completion">sudo eject /dev/sdb</PostSyncCommand>
    However, sudo eject /dev/sdb could not be run as shown below:

    Code: Select all

    Jul 12 13:26:00 pc sudo[5666]: pam_unix(sudo:auth): conversation failed
    Jul 12 13:26:00 pc sudo[5666]: pam_unix(sudo:auth): auth could not identify password for [matthew]

    Am I wrong in thinking that a system service needs no password?
    How can I make FreeFileSync run sudo eject /dev/sdb via a system service?

    Unable to initialize gtk?

    Topic is solved

    baruch60610

    In need of some credit
    In need of some credit
    Posts: 3
    Joined: Wed Sep 17, 2008 11:51 pm

    Unable to initialize gtk?

    I am very new to wxWidgets, so I’m trying to walk through some of the example programs. Some programs won’t compile, complaining of a missing «sample_xpm» file. OK, so I skip those.

    When I *do* manage to get something compiled, when I try to run that program it says:

    «Error: Unable to initialize gtk, is DISPLAY set properly?»

    I have tried searching through the Website and the form, but don’t find anything about this. Can someone direct me to a good reference or other source of info? Thanks.

    Auria

    Site Admin
    Site Admin
    Posts: 6695
    Joined: Thu Sep 28, 2006 12:23 am
    Contact:

    Post

    by Auria » Thu Sep 18, 2008 12:33 am

    What is your system? How did you install wxWidgets? How are you building samples?

    baruch60610

    In need of some credit
    In need of some credit
    Posts: 3
    Joined: Wed Sep 17, 2008 11:51 pm

    Post

    by baruch60610 » Thu Sep 18, 2008 1:06 am

    Sorry I omitted this vital info…

    I’m using Linux — Ubuntu 8.04. I originally tried using the binary that’s in the repository (using synaptic to install it), but this was ineffective.

    I then got the tarball and installed it, and ran ldconfig afterwards.

    mc2r

    wxWorld Domination!
    wxWorld Domination!
    Posts: 1195
    Joined: Thu Feb 22, 2007 4:47 pm
    Location: Denver, Co
    Contact:

    Re: Unable to initialize gtk?

    Post

    by mc2r » Thu Sep 18, 2008 2:10 am

    baruch60610 wrote:«Error: Unable to initialize gtk, is DISPLAY set properly?«

    Just on a hunch from above, are you maybe ssh’d(hope not telneted) into a linux server that you are trying to run this from and not from a local shell?

    regardless whatever shell you are running this from needs to know which DISPLAY to use for any windows/gui elements.

    run the following in the shell and you should see if there is a DISPLAY set and if so what it is.

    you should see something like this

    if you arent ssh’d in and the shell is on the local machine I’d try running this from the shell

    note you might have a different display and will have to adjust accordingly. I have no idea what it would be, depends on how your machine is set up.

    if ssh’d in try ssh’ing with the -X flag, it enables X11 forwarding.

    Code: Select all

    ssh -X somemachine.somenetwork.com

    Maybe some of that will help

    -Max

    PS: don’t know why you are getting warnings about sample_xpm.

    Auria

    Site Admin
    Site Admin
    Posts: 6695
    Joined: Thu Sep 28, 2006 12:23 am
    Contact:

    Post

    by Auria » Thu Sep 18, 2008 3:19 pm

    baruch60610 wrote:Sorry I omitted this vital info…

    I’m using Linux — Ubuntu 8.04. I originally tried using the binary that’s in the repository (using synaptic to install it), but this was ineffective.

    I then got the tarball and installed it, and ran ldconfig afterwards.

    okay, but can you describe the commands you used to install wx, and also what commands you are using to build the samples, and using what makefiles. mc2r may be right, but the fact that some of them fail also hints you perhaps you’re doing something wrong in the build process

    baruch60610

    In need of some credit
    In need of some credit
    Posts: 3
    Joined: Wed Sep 17, 2008 11:51 pm

    Post

    by baruch60610 » Fri Sep 19, 2008 2:50 am

    Note: I believe that my X server had been the source of problems. I may have hosed it while playing around with wxWidgets. When I booted up today, the demo programs seemed to work. Since I didn’t rebuild any of them, I assume it had something to do with the X server, and not wxWidgets. As I said, I’m very new to this, and I was confused by the error message.

    As far as I can tell, the display problem is no longer active, so for now I’ll just say thanks for your helpful ideas.

    • Index
    • » Newbie Corner
    • » [Solved}Error: Unable to initialize gtk, is DISPLAY set properly?

    Pages: 1

    #1 2012-01-16 16:52:26

    sanjuchopra
    Member
    From: Gurgaon,INDIA
    Registered: 2010-08-01
    Posts: 33

    [Solved}Error: Unable to initialize gtk, is DISPLAY set properly?

    i am using aa software that require root access , but when i run it with root access is shows

    Error: Unable to initialize gtk, is DISPLAY set properly?

    I am using kde desktop , but when loginas root in kde and run that application it works fine.
    i have googled a lot on this but did not find any solution.

    Last edited by sanjuchopra (2012-01-19 10:59:39)

    #2 2012-01-16 18:33:09

    olorian
    Member
    Registered: 2011-12-16
    Posts: 86

    Re: [Solved}Error: Unable to initialize gtk, is DISPLAY set properly?

    You should NEVER login graphically as root. What software do you want to use? Is it REALLY necessary to give it root access=

    If you want to run it as root, you should do the following in a terminal:

    $ xhost +      enable X access from terminals
    $ su    login as root
    # /path/to/programname

    Or better yet if you use sudo.
    Better yet if you start the program with

    This way you’ll be asked for password and won’t need a terminal.

    By the way, if the program requires gtk to be in your sistem, maybe you should check that they’re installed, giving

    Last edited by olorian (2012-01-16 18:34:39)

    #3 2012-01-17 03:10:53

    sanjuchopra
    Member
    From: Gurgaon,INDIA
    Registered: 2010-08-01
    Posts: 33

    Re: [Solved}Error: Unable to initialize gtk, is DISPLAY set properly?

    software is extremeburner , gui for avrdude.It is mentioned that it require root access.

    #4 2012-01-17 03:35:31

    skunktrader
    Member
    From: Brisbane, Australia
    Registered: 2010-02-14
    Posts: 1,502

    Re: [Solved}Error: Unable to initialize gtk, is DISPLAY set properly?

    #5 2012-01-19 06:48:29

    sanjuchopra
    Member
    From: Gurgaon,INDIA
    Registered: 2010-08-01
    Posts: 33

    Re: [Solved}Error: Unable to initialize gtk, is DISPLAY set properly?

    #6 2012-01-19 10:49:23

    karol
    Archivist
    Registered: 2009-05-06
    Posts: 25,440

    Re: [Solved}Error: Unable to initialize gtk, is DISPLAY set properly?

    Please remember to mark the thread a solved.

    Понравилась статья? Поделить с друзьями:
  • Error unable to get shsh blobs for this device recovery os root ticket
  • Error unable to get cib
  • Error unable to find vcvarsall bat
  • Error unable to find splash resources age of mythology что делать
  • Error unable to find library