grnet / ganetimgr Goto Github PK
View Code? Open in Web Editor NEWGanetimgr is a Django application that manages Ganeti clusters
Home Page: https://grnet.github.io/ganetimgr/
License: GNU General Public License v3.0
Ganetimgr is a Django application that manages Ganeti clusters
Home Page: https://grnet.github.io/ganetimgr/
License: GNU General Public License v3.0
The table in the VM listing page get its dimension on load time and will not follow browser resizing despite ample space being available. A refresh will redraw the table along the new browser window size resolving the problem but still...
Dear devs,
Testing v1.6.0 with localization to Russian.
Changing settings.py
LANGUAGE_CODE = 'ru-Ru'
returns an AttributeError: 'NoneType' object has no attribute '_info'
The issue #51 seems to related to this one.
I found one solution which is specific to Django Version 1.4.5:
https://code.djangoproject.com/ticket/18192
where one has to fix the file
ganetimgr/lib/python2.7/site-packages/django/utils/translation/trans_real.py
like this:
def _translation(path):
try:
t = gettext_module.translation('django', path, [loc], DjangoTranslation)
t.set_language(lang)
return t
except IOError:
return None
res = _translation(globalpath)
### salsa: THIS CODE I have to add before running syncdb
if res is None:
return gettext_module.NullTranslations()
# We want to ensure that, for example, "en-gb" and "en-us" don't share
# the same translation object (thus, merging en-us with a local update
# doesn't affect en-gb), even though they will both use the core "en"
# translation. So we have to subvert Python's internal gettext caching.
base_lang = lambda x: x.split('-', 1)[0]
if base_lang(lang) in [base_lang(trans) for trans in _translations]:
res._info = res._info.copy() ### salsa: HERE it throws AttributeError
res._catalog = res._catalog.copy()
following the instruction in the manual will result in an uncompleat database
root@precise64:/srv/www/ganetimgr# python manage.py syncdb --noinput
Syncing...
Creating tables ...
Creating table auth_permission
Creating table auth_group_permissions
Creating table auth_group
Creating table auth_user_user_permissions
Creating table auth_user_groups
Creating table auth_user
Creating table auth_message
Creating table django_content_type
Creating table django_session
Creating table django_site
Creating table django_flatpage_sites
Creating table django_flatpage
Creating table django_admin_log
Creating table south_migrationhistory
Creating table registration_registrationprofile
Installing custom SQL ...
Installing indexes ...
No fixtures found.
Synced:
django.contrib.auth
django.contrib.contenttypes
django.contrib.sessions
django.contrib.sites
django.contrib.flatpages
django.contrib.messages
django.contrib.admin
django.contrib.staticfiles
south
registration
Not synced (use migrations):
accounts:0001_initial
(faked)
accounts:0002_auto__add_field_userprofile_force_logout_date
(faked)
Adding permission 'accounts | user profile | Can add user profile'
Adding permission 'accounts | user profile | Can change user profile'
Adding permission 'accounts | user profile | Can delete user profile'
Running migrations for ganeti:
ganeti:0001_initial
(faked)
ganeti:0002_add_fast_create_field
(faked)
ganeti:0003_add_network_model
(faked)
ganeti:0004_add_default_disk_template_field
(faked)
ganeti:0005_view_instances
(faked)
ganeti:0006_auto__add_instanceaction
(faked)
ganeti:0007_auto__add_field_instanceaction_action_value
(faked)
ganeti:0008_auto__add_field_network_ipv6_prefix
(faked)
ganeti:0009_auto__chg_field_network_ipv6_prefix
(faked)
ganeti:0010_auto__chg_field_instanceaction_cluster__chg_field_instanceaction_insta
(faked)
ganeti:0011_auto__add_field_cluster_use_gnt_network
(faked)
ganeti:0012_auto__add_field_cluster_disable_instance_creation
(faked)
Adding permission 'ganeti | cluster | Can add cluster'
Adding permission 'ganeti | cluster | Can change cluster'
Adding permission 'ganeti | cluster | Can delete cluster'
Adding permission 'ganeti | cluster | Can view all instances'
Adding permission 'ganeti | network | Can add network'
Adding permission 'ganeti | network | Can change network'
Adding permission 'ganeti | network | Can delete network'
Adding permission 'ganeti | instance action | Can add instance action'
Adding permission 'ganeti | instance action | Can change instance action'
Adding permission 'ganeti | instance action | Can delete instance action'
Running migrations for apply:
apply:0001_initial
(faked)
apply:0002_add_ssh_public_key_model
(faked)
apply:0003_add_ssh_key_fingerprint
(faked)
apply:0004_add_application_cookie
(faked)
apply:0005_add_application_network_field
(faked)
apply:0006_remove_application_cluster_field
(faked)
apply:0007_add_admin_comments
(faked)
apply:0008_add_organization_tag_and_email
(faked)
Adding permission 'apply | organization | Can add organization'
Adding permission 'apply | organization | Can change organization'
Adding permission 'apply | organization | Can delete organization'
Adding permission 'apply | instance application | Can add instance application'
Adding permission 'apply | instance application | Can change instance application'
Adding permission 'apply | instance application | Can delete instance application'
Adding permission 'apply | instance application | Can view all applications'
Adding permission 'apply | ssh public key | Can add ssh public key'
Adding permission 'apply | ssh public key | Can change ssh public key'
Adding permission 'apply | ssh public key | Can delete ssh public key'
Autofocus keyboard input on important fields, i.e. username field on login and search on index.
Hi,
In the details page of an instance, could you please add a field displaying the disk-template type (plain, drbd...) of an instance ?
Right now, it seems that there's no way to get that information within ganetimgr
Thanks !
ganetimgr supports two console types: java and novnc. Once novnc is setup the web interface has two buttons: Console (WebSock) and Console (Java)
The Java console button can't be disabled, so I tried to set it up, but I can't find instructions on this.
It initially fails with "No such file or directory":
/srv/www/ganetimgr/util/vapclient.py in request_forwarding
ctrl.connect(CTRL_SOCKET) ...
▶ Local vars
/usr/lib/pymodules/python2.7/gevent/socket.py in connect
raise error(result, strerror(result))
But if I start a twisted vncap on that unix socket using
twistd --pidfile=/tmp/proxy.pid -n vncap -c unix:/var/run/vncauthproxy/vncproxy.sock
then it just hangs waiting for a response from http://<host>/cluster/<cluster>/<instance>/vnc
I notice the request format in request_forwarding() uses a different format than request_novnc_forwarding():
req = {
"source_port": int(sport),
"destination_address": daddr,
"destination_port": int(dport),
"password": password
}
vs.
request = {
"daddr": daddr,
"dport": dport,
"password": password,
"ws": True,
"tls": tls,
}
So does it require a different VNC proxy, and if so, what is it?
settings.py.dist contains examples like this:
OPERATING_SYSTEMS = {
"debian-wheezy": {
"description": "Debian Wheezy 64 bit",
"provider": "image+default",
"osparams": {
"img_id": "debian-wheezy",
"img_format": "tarball",
},
"ssh_key_param": "img_ssh_key_url",
},
The use of "image+default" suggests that these are for ganeti-instance-image. However the img_id and img_format parameters belong to snf-image.
It would be clearer if the examples were changed to:
"provider": "snf-image+default",
Missing in the install documentation:
edit /etc/default/beanstalkd
## Uncomment to enable startup during boot.
START=yes
service beanstalkd start
Network allocation diagram is not shown on instance application when net is full.
Hi,
I had a problem in migrate process, while the dbsync is OK.
The returned error was:
Running migrations for accounts:
Migrating forwards to 0002_auto__add_field_userprofile_force_logout_date.
accounts:0001_initial
accounts:0002_auto__add_field_userprofile_force_logout_date
Loading initial data for accounts.
No fixtures found.
Running migrations for ganeti:
Migrating forwards to 0012_auto__add_field_cluster_disable_instance_creation.
ganeti:0001_initial
ganeti:0002_add_fast_create_field
ganeti:0003_add_network_model
ganeti:0004_add_default_disk_template_field
ganeti:0005_view_instances
Migration 'ganeti:0005_view_instances' is marked for no-dry-run.
ganeti:0006_auto__add_instanceaction
ganeti:0007_auto__add_field_instanceaction_action_value
ganeti:0008_auto__add_field_network_ipv6_prefix
ganeti:0009_auto__chg_field_network_ipv6_prefix
ganeti:0010_auto__chg_field_instanceaction_cluster__chg_field_instanceaction_insta
! Error found during real run of migration! Aborting.
! Since you have a database that does not support running
! schema-altering statements in transactions, we have had
! to leave it in an interim state between migrations.
! You might be able to recover with:
! The South developers regret this has happened, and would
! like to gently persuade you to consider a slightly
! easier-to-deal-with DBMS.
! NOTE: The error which caused the migration to fail is further up.
Traceback (most recent call last):
File "./manage.py", line 29, in
execute_manager(settings)
File "/usr/lib/python2.7/dist-packages/django/core/management/init.py", line 438, in execute_manager
utility.execute()
File "/usr/lib/python2.7/dist-packages/django/core/management/init.py", line 379, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/usr/lib/python2.7/dist-packages/django/core/management/base.py", line 191, in run_from_argv
self.execute(_args, *_options.dict)
File "/usr/lib/python2.7/dist-packages/django/core/management/base.py", line 220, in execute
output = self.handle(_args, *_options)
File "/usr/lib/python2.7/dist-packages/south/management/commands/migrate.py", line 105, in handle
ignore_ghosts = ignore_ghosts,
File "/usr/lib/python2.7/dist-packages/south/migration/init.py", line 191, in migrate_app
success = migrator.migrate_many(target, workplan, database)
File "/usr/lib/python2.7/dist-packages/south/migration/migrators.py", line 221, in migrate_many
result = migrator.class.migrate_many(migrator, target, migrations, database)
File "/usr/lib/python2.7/dist-packages/south/migration/migrators.py", line 292, in migrate_many
result = self.migrate(migration, database)
File "/usr/lib/python2.7/dist-packages/south/migration/migrators.py", line 125, in migrate
result = self.run(migration)
File "/usr/lib/python2.7/dist-packages/south/migration/migrators.py", line 99, in run
return self.run_migration(migration)
File "/usr/lib/python2.7/dist-packages/south/migration/migrators.py", line 81, in run_migration
migration_function()
File "/usr/lib/python2.7/dist-packages/south/migration/migrators.py", line 57, in
return (lambda: direction(orm))
File "/srv/www/ganetimgr/../ganetimgr/ganeti/migrations/0010_auto__chg_field_instanceaction_cluster__chg_field_instanceaction_insta.py", line 12, in forwards
db.alter_column('ganeti_instanceaction', 'cluster_id', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['ganeti.Cluster'], null=True, blank=True))
File "/usr/lib/python2.7/dist-packages/south/db/generic.py", line 397, in alter_column
field.rel.to._meta.get_field(field.rel.field_name).column
File "/usr/lib/python2.7/dist-packages/south/db/generic.py", line 150, in execute
cursor.execute(sql, params)
File "/usr/lib/python2.7/dist-packages/django/db/backends/mysql/base.py", line 86, in execute
return self.cursor.execute(query, args)
File "/usr/lib/python2.7/dist-packages/MySQLdb/cursors.py", line 174, in execute
self.errorhandler(self, exc, value)
File "/usr/lib/python2.7/dist-packages/MySQLdb/connections.py", line 36, in defaulterrorhandler
raise errorclass, errorvalue
_mysql_exceptions.OperationalError: (1005, "Can't create table 'ganetimgr.#sql-60c_80' (errno: 121)")
r
I really appreciate if you can walk me to resolve this.
Thanks,
Andi
currently sorting by descending disk size seems to consider a 2Tb disk smaller than a 1Gb disk.
Hi!
I've been trying your Stable/Master/Dev versions of ganetimgr for snf-image OS provider and always get the same error on application/$id/review page just under the "Operating System" with text in red saying
"Δεν βρέθηκε το λειτουργικό που ζητηθηκε: debian_base-7.0-x86_64"
when submiting the Application I get (in v1.5.5 of ganetimgr) the TypeError in "/srv/www/ganetimgr/apply/models.py in submit, line 196" of "
'NoneType' object has no attribute 'getitem'".
This is coded in
ganetimgr/templates/review.html
Line 601 in 16b2be5
It is ok when I use just "img_id": "debian-base" for ex. in settings.py for snf-image+default provider.
Could you please have a look at it?
I would appreciate solving this issue as soon as possible because it stops me from going further in deploying a testbed Ganeti cluster.
Thanks! Serge
Hi,
after a while I figured out that for Django 1.7 the locale folder needs to be moved into the ganeti/ subfolder (mv locale ganeti/) to work again.
See https://docs.djangoproject.com/en/dev/topics/i18n/translation/#how-django-discovers-translations
Mike
A user with the "ganeti | cluster | Can view all instances " permission can query the status of all the instances from all the clusters from the main page but gets (Access denied) when trying to access a instance page (e.g. /cluster///).
The following error occurs when a username contains the @ character:
NoReverseMatch: Reverse for 'user-info' with arguments '(u'user', u'[email protected]')' and keyword arguments '{}' not found.
Hi, devs!
Code in util/vapclient.py of the master branch says we must use the snf-vncauthproxy of the version prior to 1.5 when Unix domain control sockets were replaced with TCP control sockets:
CTRL_SOCKET = "/var/run/vncauthproxy/vncproxy.sock"
Right now I'm deploying GanetiMGR (master branch) with https://github.com/grnet/snf-vncauthproxy (master, v1.6). And I'm working towards rewriting some code to support that.
Is there any specific reason for using Unix domain control socket?
I can't find any documentation of what COLLECTD_URL is supposed to point to. I poked around at some of the collectd frontends I could find and none seem to have a matching URL format to what ganetimgr generates.
From /var/log/ganeti/watcher.log
...
05/25/2014 12:08:32 PM Checking host89.ws.nsrc.org (job: 2171)
05/25/2014 12:08:32 PM host89.ws.nsrc.org (job: 2171) done. Status: success
05/25/2014 12:08:32 PM Mailing [email protected] about host89.ws.nsrc.org
05/25/2014 12:08:32 PM Handling host89.ws.nsrc.org (job: 2171)
05/25/2014 12:08:47 PM Checking host89.ws.nsrc.org (job: 2171)
05/25/2014 12:08:47 PM host89.ws.nsrc.org (job: 2171) done. Status: success
05/25/2014 12:08:47 PM Mailing [email protected] about host89.ws.nsrc.org
05/25/2014 12:08:47 PM Handling host89.ws.nsrc.org (job: 2171)
05/25/2014 12:09:02 PM Checking host89.ws.nsrc.org (job: 2171)
05/25/2014 12:09:02 PM host89.ws.nsrc.org (job: 2171) done. Status: success
05/25/2014 12:09:02 PM Mailing [email protected] about host89.ws.nsrc.org
05/25/2014 12:09:02 PM Handling host89.ws.nsrc.org (job: 2171)
05/25/2014 12:09:17 PM Checking host89.ws.nsrc.org (job: 2171)
05/25/2014 12:09:17 PM host89.ws.nsrc.org (job: 2171) done. Status: success
05/25/2014 12:09:17 PM Mailing [email protected] about host89.ws.nsrc.org
05/25/2014 12:09:17 PM Handling host89.ws.nsrc.org (job: 2171)
05/25/2014 12:09:32 PM Checking host89.ws.nsrc.org (job: 2171)
05/25/2014 12:09:32 PM host89.ws.nsrc.org (job: 2171) done. Status: success
05/25/2014 12:09:32 PM Mailing [email protected] about host89.ws.nsrc.org
05/25/2014 12:09:32 PM Handling host89.ws.nsrc.org (job: 2171)
05/25/2014 12:09:47 PM Checking host89.ws.nsrc.org (job: 2171)
05/25/2014 12:09:47 PM host89.ws.nsrc.org (job: 2171) done. Status: success
05/25/2014 12:09:47 PM Mailing [email protected] about host89.ws.nsrc.org
05/25/2014 12:09:47 PM Handling host89.ws.nsrc.org (job: 2171)
05/25/2014 12:10:02 PM Checking host89.ws.nsrc.org (job: 2171)
05/25/2014 12:10:02 PM host89.ws.nsrc.org (job: 2171) done. Status: success
05/25/2014 12:10:02 PM Mailing [email protected] about host89.ws.nsrc.org
05/25/2014 12:10:02 PM Job 4 reserved 31 (> 30) times, burying
I am guessing an exception has occurred because it doesn't say "Mailing managers about ...", but if so the exception has been silently caught, and I can't see in the code where this happens. I think it should be caught and logged
Note: this particular error was caused by no MTA being installed on the host where ganetimgr was running, and installing an MTA fixed the issue, but there were no clues in the log.
05/25/2014 01:13:49 PM Handling lock key cluster:nuc:instance:host88.ws.nsrc.org:lock (job 2203)
05/25/2014 01:13:49 PM Handling host88.ws.nsrc.org (job: 2203)
05/25/2014 01:14:04 PM Checking host88.ws.nsrc.org (job: 2203)
05/25/2014 01:14:13 PM Job 2203 finished, removing lock cluster:nuc:instance:host88.ws.nsrc.org:lock
05/25/2014 01:14:19 PM Checking host88.ws.nsrc.org (job: 2203)
05/25/2014 01:14:19 PM host88.ws.nsrc.org (job: 2203) done. Status: success
05/25/2014 01:14:19 PM Mailing [email protected] about host88.ws.nsrc.org
05/25/2014 01:14:19 PM Mailing managers about host88.ws.nsrc.org
These are very minor niggles, but:
For admin accounts, one should be able to 'Select Clusters' in Audit Log as is the case with 'Jobs'
If you approve a new instance application, but the instance creation fails, then:
To reproduce: any type of event which causes instance creation to fail will do, e.g. not having enough RAM on the cluster. However an easy-to-reproduce case is where the os-type does not exist, e.g. if you select the "noop" os type but this is not installed.
Desired behaviour: ideally leave the application queued and report the error somewhere (e.g. in the "comments to the user" box), and allow the parameters to be edited and resubmitted. Or else treat it as a rejection, and append the error in the "comments to the user"
(*) ganetimgr.log shows:
2014-03-14 00:44:34 [15454] [DEBUG] POST /application/3/review
ERROR:django.request:Internal Server Error: /application/3/review
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/django/core/handlers/base.py", line 111, in get_response
response = callback(request, *callback_args, **callback_kwargs)
File "/usr/lib/python2.7/dist-packages/django/contrib/auth/decorators.py", line 20, in _wrapped_view
return view_func(request, *args, **kwargs)
File "/srv/www/ganetimgr/apply/views.py", line 151, in review_application
application.submit()
File "/srv/www/ganetimgr/apply/models.py", line 187, in submit
b = beanstalkc.Connection()
File "/srv/www/ganetimgr/util/beanstalkc.py", line 49, in __init__
self.connect()
File "/srv/www/ganetimgr/util/beanstalkc.py", line 63, in connect
raise SocketError(e)
SocketError: [Errno 111] Connection refused
2014-03-14 00:44:40 [15454] [DEBUG] Closing connection.
DEBUG:gunicorn.error:Closing connection.
A new cluster(s) info page could be useful for admins. It could provide details such as:
Hi,
It looks like it isn't possible right now to change the vcpu/memory/network ressource allocated to an instance after it has been created in the "configuration options" section
Would it be possible to add that functionnality please ?
Thanks
Until now a VM creation get's routed to a specific cluster by choosing a network that is attached to a cluster. It would be nice to be able to have cross-cluster networks (common with bridged networks), and to be a able to both select a cluster name/slug and a network upon creation.
This probably needs a major redesign but it's probably worth it since such cases already exist.
The lower memory limit for a VM is defined in two different places, which makes it awkward if you want to allow a smaller instance. This patch avoids the duplication, so you only have to set VALID_MEMORY_VALUES.
--- a/apply/forms.py
+++ b/apply/forms.py
@@ -36,9 +36,9 @@ from django.utils.html import escape, conditional_escape
# Taken from ganeti and patched to avoid non-bind9 friendly VM names
_VALID_NAME_RE = re.compile("^[a-z0-9.-]{1,255}$")
-VALID_MEMORY_VALUES = ['512', '768', '1024', '1500', '2048', '3072', '4096']
+VALID_MEMORY_VALUES = [512, 768, 1024, 1500, 2048, 3072, 4096]
-MEMORY_CHOICES = [(m, filesizeformat(int(m) * 1024**2))
+MEMORY_CHOICES = [(str(m), filesizeformat(m * 1024**2))
for m in VALID_MEMORY_VALUES]
@@ -183,7 +183,7 @@ class InstanceApplicationForm(InstanceForm):
class InstanceApplicationReviewForm(InstanceForm):
- memory = forms.IntegerField(min_value=512, initial=1024)
+ memory = forms.IntegerField(min_value=min(VALID_MEMORY_VALUES), initial=1024)
vcpus = forms.IntegerField(min_value=1, initial=1, label="Virtual CPUs")
disk_size = forms.IntegerField(min_value=2, initial=5,
label=ugettext_lazy("Disk size (GB)"))
It seems that ganetimgr don't support new versions of Django.
A quick test on Debian Jessie gives me the following error while initializing the database:
$ python manage.py syncdb --noinput
/usr/lib/python2.7/dist-packages/registration/models.py:91: RemovedInDjango18Warning: commit_on_success is deprecated in favor of atomic.
create_inactive_user = transaction.commit_on_success(create_inactive_user)
Traceback (most recent call last):
File "manage.py", line 27, in <module>
execute_from_command_line(sys.argv)
File "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line 385, in execute_from_command_line
utility.execute()
File "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line 354, in execute
django.setup()
File "/usr/lib/python2.7/dist-packages/django/__init__.py", line 21, in setup
apps.populate(settings.INSTALLED_APPS)
File "/usr/lib/python2.7/dist-packages/django/apps/registry.py", line 115, in populate
app_config.ready()
File "/usr/lib/python2.7/dist-packages/django/contrib/admin/apps.py", line 22, in ready
self.module.autodiscover()
File "/usr/lib/python2.7/dist-packages/django/contrib/admin/__init__.py", line 23, in autodiscover
autodiscover_modules('admin', register_to=site)
File "/usr/lib/python2.7/dist-packages/django/utils/module_loading.py", line 74, in autodiscover_modules
import_module('%s.%s' % (app_config.name, module_to_search))
File "/usr/lib/python2.7/importlib/__init__.py", line 37, in import_module
__import__(name)
File "/srv/www/ganetimgr/apply/admin.py", line 44, in <module>
class ApplicationAdmin(admin.ModelAdmin):
File "/srv/www/ganetimgr/apply/admin.py", line 51, in ApplicationAdmin
actions = make_fast_create_actions()
File "/srv/www/ganetimgr/apply/admin.py", line 24, in make_fast_create_actions
for cluster in Cluster.objects.filter(fast_create=True):
File "/usr/lib/python2.7/dist-packages/django/db/models/query.py", line 141, in __iter__
self._fetch_all()
File "/usr/lib/python2.7/dist-packages/django/db/models/query.py", line 966, in _fetch_all
self._result_cache = list(self.iterator())
File "/usr/lib/python2.7/dist-packages/django/db/models/query.py", line 265, in iterator
for row in compiler.results_iter():
File "/usr/lib/python2.7/dist-packages/django/db/models/sql/compiler.py", line 700, in results_iter
for rows in self.execute_sql(MULTI):
File "/usr/lib/python2.7/dist-packages/django/db/models/sql/compiler.py", line 786, in execute_sql
cursor.execute(sql, params)
File "/usr/lib/python2.7/dist-packages/django/db/backends/utils.py", line 81, in execute
return super(CursorDebugWrapper, self).execute(sql, params)
File "/usr/lib/python2.7/dist-packages/django/db/backends/utils.py", line 65, in execute
return self.cursor.execute(sql, params)
File "/usr/lib/python2.7/dist-packages/django/db/utils.py", line 94, in __exit__
six.reraise(dj_exc_type, dj_exc_value, traceback)
File "/usr/lib/python2.7/dist-packages/django/db/backends/utils.py", line 65, in execute
return self.cursor.execute(sql, params)
File "/usr/lib/python2.7/dist-packages/django/db/backends/mysql/base.py", line 128, in execute
return self.cursor.execute(query, args)
File "/usr/lib/python2.7/dist-packages/MySQLdb/cursors.py", line 174, in execute
self.errorhandler(self, exc, value)
File "/usr/lib/python2.7/dist-packages/MySQLdb/connections.py", line 36, in defaulterrorhandler
raise errorclass, errorvalue
django.db.utils.ProgrammingError: (1146, "Table 'ganetimgr.ganeti_cluster' doesn't exist")
An option in settings.py for which VNC method to use: Java applet or noVNC.
Actions on VMs through button is really nice and cool but a user may inadvertently press one rebooting or shutting down a VM causing DoS to his own services. A dialog requesting confirmation would go a long way to avoid that
Instance rename requires that the instance is turned off. When an instance is shutdown via console or terminal, then ganeti will start it automatically. For rename to work properly, the instance need to be shutdown via ganetimgr web interface.
at /user/info/user/USERNAME there is a table showing the VMs of the user. It would be nice to have the disks column, as it appears in the home page.
or maybe have a common/reusable view/table for both pages ?
I just figured out what caused my Ganeti Mgr instance to crash on listing VMs under the Nodes submenu and the when clicking on Graphs -> Get Graphs .
The ganetimgr WebGUI does not like if the "cluster_slug" parameter of a Ganeti cluster contains the dash character ("-"). If a cluster_slug contains a slash, the UI (i.e., django) spits out this error message:
""" (when attempting to view cluster graphs)
NoReverseMatch at /graph/all/
Reverse for 'cluster-get-nodes-graphs' with arguments '()' and keyword arguments '{'cluster_slug': u'g-c_demo'}' not found.
Request Method: POST
Request URL: http://127.0.0.1:8088/graph/all/
Django Version: 1.4.5
Exception Type: NoReverseMatch
Exception Value:
Reverse for 'cluster-get-nodes-graphs' with arguments '()' and keyword arguments '{'cluster_slug': u'g-c_demo'}' not found.
Exception Location: /usr/lib/python2.7/dist-packages/django/core/urlresolvers.py in _reverse_with_prefix, line 422
Python Executable: /usr/bin/python
Python Version: 2.7.3
Python Path:
['/var/lib/ganetimgr/ganetimgr/ganetimgr',
'/var/lib/ganetimgr/ganetimgr',
'/usr/bin',
'/usr/lib/python2.7',
'/usr/lib/python2.7/plat-linux2',
'/usr/lib/python2.7/lib-tk',
'/usr/lib/python2.7/lib-old',
'/usr/lib/python2.7/lib-dynload',
'/usr/local/lib/python2.7/dist-packages',
'/usr/lib/python2.7/dist-packages',
'/usr/lib/pymodules/python2.7']
Server time: Wed, 6 May 2015 16:56:34 +0200
"""
When renaming the cluster_slug to something not containing a dash character, the WebUI renders the pages/views just fine.
Some key with details on coloured items on 'Cluster Info -> Instances' and in 'Nodegroups -> Node'
Dear devs,
How do you enable SAML authentication for GanetiMGR?
RAPI now allows passing osparams
to the reinstall call. So we can present the user with the option to Reinstall an instance with a different OS
If you create a VM with the default selection of "5GB", you get a disk which is 5242880000 bytes = 5_1000_1024*1024 bytes, so is neither 5GB nor 5GiB.
It looks like this comes from apply/models.py:
disks=[{"size": self.disk_size * 1000}],
Suggest changing this to * 1024
Sometimes both users and admins need to look back at previous actions they've done. It would be nice to keep a record of every user's action so that users of ganetimgr could see their past actions and admins could see a page with a listing of every users' action.
ganetimgr should keep a record of when a user has started/stopped/reinstalled/deleted/etc a VM, when a user has added a co-admin, when an admin locked/isolated a VM and so on.
At the admin "job listing" page we need to have filters though so we can filter by action type, by user, by cluster, by node or by VM name, etc.
It would be really helpful to have English translations of the notification E-mails:
# find /srv/www/ganetimgr/templates -name '*.txt'
/srv/www/ganetimgr/templates/pass_change_notify_mail.txt
/srv/www/ganetimgr/templates/reinstall_mail.txt
/srv/www/ganetimgr/templates/instance_created_mail.txt
/srv/www/ganetimgr/templates/application_rejected_mail.txt
/srv/www/ganetimgr/templates/registration/activation_complete.txt
/srv/www/ganetimgr/templates/registration/activation_complete_subject.txt
/srv/www/ganetimgr/templates/registration/activation_email.txt
/srv/www/ganetimgr/templates/registration/activation_email_subject.txt
/srv/www/ganetimgr/templates/apply_mail.txt
/srv/www/ganetimgr/templates/idle_account.txt
Whilst this could be done fairly easily with the help of Google Translate, there's currently no place to store multiple language versions of each E-mail.
One option might be to rename these to *.el.txt so that *.en.txt can sit alongside. However all the code which calls email = render_to_string("name_of_template.txt", ...)
would need to be changed. Would the language have to become a per-user profile setting?
As a short-term fix, these mail bodies could have Greek with the English translation in-line below.
In a specific VM's page, the services line icons are being displayed to point out the services (like Mail Server?) available to this. While the icons are nice and quite explanatory, for completeness sake tooltips should be provided as well
The install instructions don't say you need to change NODATA_IMAGE for the graph to display correctly when insufficient data is present.
However a one-line patch makes this automatic.
--- a/settings.py.dist
+++ b/settings.py.dist
@@ -285,7 +285,7 @@ SW_VERSION = _version.VERSION
# Rapi request timeout in gevent calls in seconds
RAPI_TIMEOUT = 15
-NODATA_IMAGE = "/path/to/static/nodata.jpg"
+NODATA_IMAGE = STATIC_ROOT + "nodata.jpg"
WHITELIST_IP_MAX_SUBNET_V4 = 26
WHITELIST_IP_MAX_SUBNET_V6 = 64
The RSS icon on latest news creates the impression that users can use any RSS reader to subscribe to an RSS feed informing them about the service. A different icon would avoid that confusion
It would be nice if ganetimgr had an extra field in the instance boot-configuration, for specifying an sha1sum (which could be copy-pasted) to use to verify an ISO image when it's being booted from an http URL. If that's not always possible it could just be an optional field (skipping the check if empty). The local patches to ganeti-instance-image do this under the hood anyway, so it should be
trivially easy to implement in the UI, and would be much safer against MITM attacks.
Dear devs,
I'm testing v1.6.0 with localization to russian.
After changing language in the web interface to a localized one changing back to English doesn't work (nothing happens). The same actually happens with Greek.
The small icons displaying possible VM actions are quite nice but not always self explanatory. Tooltips could be added to provide a hit on what each button does
When using the web interface in my profile page with the browser window width less than 1540 px then some input fields might become chopped and not appear in their entirety onscreen. This problem stops when the browsers width is resized below 743 px and the three boxes align vertically instead of horizontally
Using google chrome on Debian wheezy, pixel numbers could vary depending on fonts used I assume
Add alphanumeric sorting in 'Nodegroups -> Nodes' for each node group
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.