Summary of the invention
Can not provide multiple base application for overcoming conventional network equipment, and server is too complicated, use the shortcoming of trouble, the present invention proposes a kind of novel multifunctional network application apparatus, described multifunctional network application equipment promptly has the general network device to use for a long time, the reliability height, need not the complicated advantage that is provided with, the server that has common PC or work station to build again can provide the advantage of base application, for example can provide the fire compartment wall of webpage, enterprise's mailbox, enterprise-level, the network hard disc of enterprise-level, network application system of enterprise-level or the like.For adapting to the operational mode of the described network equipment, the present invention proposes the method for a kind of startup and the described network equipment of online upgrading.This method has been abandoned usually simple Linux of reduction or UNIX method, has proposed a kind of new framework and new operational mode.Described method will be installed operating file storage and be separated fully with running space, separately independence.All device operating files are stored on the medium with modular structure all according to ad hoc rules and requirement.After device started, operating device operating file just separated independent operating with storage medium.User's service document adopts modularization, and upgrade-system is simple, convenient, only need get final product according to the regular down loading updating in real time of storage organization.Described method adopts brand-new start-up mode, and operational mode is divided into primal system and two aspects of service system, adopts the independent operating mode that does not rely on hard disk or other storage mediums.
The object of the present invention is achieved like this: a kind of multifunctional network application equipment comprises: mainboard, and central processing unit, random asccess memory, hard disk, WAN, LAN interface, USB interface is characterized in that, single-chip microcomputer, LCD MODULE, system's storage card; Described central processing unit directly is connected on the mainboard, described random asccess memory is connected with central processing unit by the slot on the mainboard, described hard disk is connected with central processing unit by the interface on the mainboard, described single-chip microcomputer is connected with mainboard by interface, described LCD MODULE is connected with single-chip microcomputer, described system storage card is connected with mainboard by interface, described WAN, LAN interface, and USB interface directly is connected with mainboard.
Mainboard is a kind of main board of industrial control computer that has various PC interfaces.System's storage card is operating system, application system optimization, cutting, and combine as a whole with the hardware store card, the employed memory element of system's storage card is a flash memory, it can be the CF card, it also can be the DOM card, system's storage card is connected with DOM card or CF card converting interface by ide interface with mainboard, and single-chip microcomputer is connected by the RS232 interface with mainboard, and LCD MODULE is monochromatic multirow lattice lcd plate.
A kind of startup method of multifunctional network application equipment, described multifunctional network application equipment comprises: mainboard, central processing unit, random asccess memory, hard disk, WAN, LAN interface, USB interface, single-chip microcomputer, LCD MODULE, system's storage card is characterized in that described step:
Start, the step of loading system card;
The system card start-up system is obtained initialization micro-system mirror image, creates the step in micro-system space in random asccess memory;
Load the initialization micro-system, and the step of in specifying the random asccess memory space, launching;
The Load System kernel, the step of establishment fundamental system environment;
Load the ext3 file system module, and the step of other basic module;
Create the dynamic random access memory system space, make up the dynamic random access memory virtual disk, discharge root system and unite in the dynamic random access memory virtual disk, and make up the step of root system system;
The unite step of dynamic random access memory virtual disk of conversion root system;
Create the step of root file system;
The step of initialization system;
Discharge the related application module according to configuration file, make up the step of user's application system;
The step of uninstalling system card.
A kind of online upgrading method of multifunctional network application equipment, described multifunctional network application equipment comprises: mainboard, central processing unit, random asccess memory, hard disk, WAN, LAN interface, USB interface, single-chip microcomputer, LCD MODULE, system's storage card is characterized in that, two subregion storage organizations, the step of online upgrading:
Upgrade-system connects upgrade server upgrade service port;
Server authentication upgrade-system legitimacy;
Upgrade-system obtains data message to be upgraded;
Upgrade-system is made comparisons upgrade data information and this machine data, obtains the upgrading tabulation;
Upgrade-system download and upgrade module;
Carry system storage card;
The update system module;
The uninstalling system storage card, upgrading is finished.
Described two subregion storage organizations are: whole storage area is divided into two subregions, boot partition, storage system kernel and guidance system; Data partition is deposited all application systems, application service module;
The data partition structure: data partition has only a data catalogue, and all contents all are application service module in the data directory.Application service module is according to application service module rule sign, definition and storage, and system distinguishes according to the application service module rule and loads different application service modules.
Described application service module sign, definition rule:
If module name starts with N, be inaction module, do not load, other are active module;
S000 is conventional module to S499, the unconditional loading:
Module with the S0 beginning is the infrastructure service module, is the initial data of all infrastructure services, does not comprise self-defining data, configuration file;
Module with the S1 beginning is the infrastructure service companion module, is the self-defining data that can satisfy the demands when stating infrastructure service in the use, configuration file;
Be the expansion service module that system provides when dispatching from the factory with the module of S2 beginning, similar with S0;
Be the expansion service companion module that system provides when dispatching from the factory with the module of S3 beginning, similar with S1;
S400-S499 is standby number of conventional module;
S500 is big data module to S999, only has just loading under the situation of hard disk:
Module with the S5 beginning is the high-level service module, is the initial data of all high-level service, does not comprise self-defining data, configuration file;
Module with the S6 beginning is a high-level service module companion module, is the self-defining data that can satisfy the demands when stating high-level service in the use, configuration file;
Be the senior expansion service module that system provides when dispatching from the factory with the module of S7 beginning, similar with S5;
Be the senior expansion service companion module that system provides when dispatching from the factory with the module of S8 beginning, similar with S6;
S900-S999 is standby number of big data module.
The beneficial effect that the present invention produces is: owing to used a kind of main board of industrial control computer that has various PC interfaces, reliability of the present invention is improved greatly, simultaneously realized that again various interface is connected with the flexible of peripheral hardware, both realized the function of server, again can reliable continuous operation as the network equipment.Owing to used system's storage card, all device operating files all are installed in system's storage card, the software and hardware integration design, removed the trouble of configure hardware, install software from, make installation simple and convenient, be easy to use, operate, non-technical personnel also can be managed, and removes product later maintenance work from.Owing to adopt storage device operating file in the storage card, running gear operating file method in random asccess memory, make the operation of device operating file and store relatively independent, can also prevent effectively that the locking apparatus operating file suffers the invasion of virus, can as the network equipment equally do not fear virus.The present invention can be regarded as a kind of network application server of simplification, just simplify and fallen some, mask redundant interface, make the product external interface simpler the unnecessary hardware and software of network service, need not to connect complicated ancillary equipment, only need to connect two netting twines and can drop into application.The present invention simplifies the display part, replace expensive display and the display module in video card and the software with simple single-chip microcomputer and LCD panel, acquisition cost is reduced, once drop into and promptly obtain all and use substantially, remove enterprise's high investment from, the informationization of low effect is worried.The present invention can provide multiple base application, for example: the fire compartment wall of enterprise's webpage, enterprise's mailbox, enterprise-level is provided, the network hard disc of enterprise-level, the network application system of enterprise-level, FTP, gateway or the like, and can expand application according to demand.
Because the system core, service system, application system and user data are fully separately deposited, the core document system adopts read-only mode, makes security of system higher.Because the pattern that the employing system separates with disk, the system that makes can not rely on disk and normal operation, guarantee the reliable and stable of system service.Owing to adopt system modular, can add/upgrade a functional module at any time, and it goes without doing any adjustment of other modules of system, thereby but realize the assembly unit of system.And make renewal/upgrading then extremely effectively simple, can very easily realize the application extension of system by network.
Embodiment
Embodiment one:
Fig. 1, Fig. 2 are the profile schematic diagram and the theory diagrams of multifunctional network equipment, and what the sequence number among the figure was represented is: 1.WAN line, 2.LAN line, 3. power line, 4. multifunctional network application equipment, 5. LCD MODULE, 6.WAN interface, 7.LAN interface, 8.USB interface, 9. random asccess memory, 10. hard disk, 11. central processing units, 12. system's storage cards, 13. mainboard, 14. single-chip microcomputers.
As shown in Figure 1, present embodiment is seen very simple from appearance, and wiring has only WAN line 1, LAN line 2 and power line 3 usually to external world, and is suitable with general networking equipment.WAN line 1, LAN line 2 all are general crystal head joints, are easy to connect and operation.The employed LCD MODULE of present embodiment is the very low monochromatic multirow dot matrix LCD of a kind of cost, and shown information enough present embodiment is used.
As shown in Figure 2, the present embodiment basic comprising comprises: mainboard 13, central processing unit 11, random asccess memory 9, hard disk 10, WAN, LAN interface 6,7, USB interface 8, single-chip microcomputer 14, LCD MODULE 5, system's storage card 12.
The basic ideas of present embodiment are: hardware system and the operating system of simplifying common server.Application system optimization is simplified to hardware system minimum, the cutting software systems, and carry out modularization and handle, make it to become a kind of multifunctional network application equipment special use of the present invention " device operating file ".The device operating file masks redundant interface, makes the external interface of present embodiment simpler, need not to connect complicated ancillary equipment, only needs to connect two netting twines and can drop into application, improves the speed of service simultaneously.
The device operating file is in careful consideration of when design problem that combines with the hardware store card, thus formation dedicated system storage card.This system storage card makes software systems and hardware system in conjunction with as a whole.When system's storage card was inserted on the multifunctional network application equipment, the device operating file in system's storage card can't be revised, and has only under special circumstances, will block in the slave unit and extract, and was connected the content that just can revise on other computers wherein.The purpose of doing like this is the simplification that is provided with that makes the device operating file, and guarantees that this software avoids virus infraction.The hardware of system's storage card is ScanDisk CF128M or DOM128M, and system's storage card is connected with mainboard by interface.For guaranteeing the fail safe and the stability of system.Select the type of components and parts meticulously, can continuous operation lay good basis, take into account the components and parts cost simultaneously, strive for producing greatest benefit with minimum input for equipment.
For realizing the condition monitoring to multifunctional network application equipment, present embodiment is by design and develop independently single-chip microcomputer liquid crystal display systems, makes the user can be directly acquainted with the operating state and the configuration information of equipment.Saved that complicated display system is soft, hardware and expensive display.
For obtaining higher reliability, CPU that present embodiment uses and mainboard are C3 1G/EPIA, Mini-ITX DP10000.This is a kind of more special mainboard, is a kind of industrial computer mainboard, and for improving reliability, the central processing unit of this mainboard directly is welded on the mainboard, and the technology of of this sort design and assurance reliability has many places to embody on this mainboard.With common main board of industrial control computer be not both the interface that this mainboard has just to be had on some ordinary PC, use these interfaces and can connect various external equipments very easily, realize the function that could realize on some ordinary PC.Employed Kingstone 256M DDR random asccess memory is connected with central processing unit by the slot on the mainboard as common PC.Equally, the hard disk of Seagate 80G 7200rpm is connected with central processing unit by the interface on the mainboard.
For reducing cost, present embodiment is simplified display system, and the P89C52 single-chip microcomputer of use is connected with mainboard by interface, and a kind of LCD122 cheaply * 32 LCD MODULE are connected with single-chip microcomputer.This monochromatic dot matrix lcd module has enough shown necessary information.Single-chip microcomputer has replaced complicated display device, and except that the information of necessity, other redundancy sections are removed without exception, and display speed and efficient are provided greatly, has saved the hardware and software resource.USB interface 8 directly is connected with mainboard, is used for spread foundation and uses.
Embodiment two:
What present embodiment was narrated is the startup method of multifunctional network application equipment.What multifunctional network application equipment used is a kind of embedded computer system of industrial computer formula, and this embedded computer system approaches the general purpose PC system, employing be the disk service mode.Promptly the root position of system file is all the time in disk in running, and disk is in operation and can not separates with other parts of computer as the pith of computer run.The described startup method of present embodiment is a kind of start-up mode of brand-new embedded system, abandoned the disk service mode that traditional embedded system generally adopts, the root position of the device operating file of special use is transferred to the random asccess memory from the disk of routine, and the finishing device operating file loads in random asccess memory, device operating file original directory structure construction and user right distribute or the like task.Disk only plays the effect of a storage device operating file like this, and is irrelevant with operation in whole computer run process, can break away from computer, thereby realize the independence of device operating file and service, improved the stability and the reliability of system.
The employed hardware of present embodiment is that embodiment one described multifunctional network application equipment comprises: mainboard, central processing unit, random asccess memory (internal memory), hard disk, WAN, LAN interface, USB interface, single-chip microcomputer, LCD MODULE, system's storage card.The startup method of described multifunctional network application equipment is based on having made up novel system configuration.Traditional system file storage configuration is subsystem and service file not, mixed storage.Though such deposit method is simple, be not easy to management.The device operating file storage configuration of the described multifunctional network application equipment of present embodiment startup method is that various files are become class is primitive apparatus operating file and the management of two aspects of service operating file, the primitive apparatus operating file has the most basic guiding function, normally access to plant operation, without any service, has complete bibliographic structure, shell-command and support storehouse, and all operations in random asccess memory (internal memory).Here be fundamental system framework Basic System Frame (abbreviating BSF as) with this random access memory system organization definition.All serve file associated with the user and be packaged as module according to " application service module rule " definition, these modules are referred to as " application service module ".All application service modules are deposited in the designated directory according to " application service module rule ", BSF and application service module all leave in the disk, here said disk can be hard disk or external flash card (DOM/CF card), and what present embodiment used is the DOM card.When embedded system brings into operation, at first guide BSF, be about to the most basic guiding function and the complete middle operation of bibliographic structure, shell-command and support storehouse introducing random asccess memory (internal memory).After BSF guides, the primitive apparatus operating file is according to user configuration information, all application service modules of listing in this catalogue of selective loading, and in disk, extract, be placed on the service system that makes up the user in the random asccess memory (internal memory), thereby realized the assembly unit of system.The key here is the transfer of run location, be to use the variation of hardware, configuration file that the user is required and the data file of need preserving then leave on disk or the external system flash card (DOM/CF card), just when loading service, start uses, in case normal operation, disk or external system flash card just can break away from.If poisoning intrusion is arranged, the device operating file that is moving in the just random asccess memory (internal memory) of contamination, and the device operating file in disk or the external system flash can not be polluted, and remain intact.In case the device operating file of operation is owing to contamination is collapsed in the random asccess memory (internal memory), device operating file in disk or the external system flash also keeps pure, good state, as long as at this moment restart multifunctional network application equipment, the system that loads in disk or the external system flash just can guarantee that the normal network equipment has moved, and has so just really realized the safe, reliable of core system.
Described multifunctional network application equipment startup method has adopted random access memory system and disk stores synchronized structure aspect memory structure, and will install data, service and the user data of operating file, the pattern that configuration is separately deposited, make the device operating file be no longer dependent on hard disk existence and can independent operating, further improved the stability and the reliability of system.
Present embodiment based on the Linux framework title Red Hat Linux (2.4.20-8) root (he0,0) kernel/vmlinuz-2.4.20-8 ro initrd/initrd-2.4.20-8.ing} starts running, as shown in Figure 3, is described below:
1. start, the loading system card;
2. system card start-up system (boot loader) is obtained initialization micro-system mirror image (initrd/initrd-2.4.20-8.img), creates the micro-system space in random asccess memory;
3. load the initialization micro-system, and in specifying the random asccess memory space (/dev/ram) launch;
4. Load System kernel (kernel/vmlinuz-2.4.20-8.ro) is created the fundamental system environment;
5. load ext 3 file system modules, and other basic module;
6. create dynamic random access memory system space (d-ram), make up dynamic random access memory virtual disk (d-ram-vdisk), discharge root system system (root) in the dynamic random access memory virtual disk, and make up the root system system;
7. the conversion root system dynamic random access memory virtual disk of uniting;
8. establishment root file system;
9. initialization system (/etc/rc.d/rc.sysinit rc3.d);
10. discharge the related application module according to configuration file, make up user's application system;
11. uninstalling system card.
Embodiment three:
What present embodiment was narrated is the online upgrading method of multifunctional network application equipment.
The device operating file of traditional embedded system is with the form storage of some files, and storage and all interactive operations in same memory space of operation, installs in the operating file running, is mostly the form of monopolizing for storage file.The upgrade-system complexity need take into full account dependence and running status between the device operating file, and the careless slightly device operating file that will cause collapses, and therefore, embedded system is not made the online upgrading function substantially.The tradition embedded system storage organization as shown in Figure 4:
1. boot partition, the system bootstrap routine storage area;
2. system partitioning, storage system kernel and system file;
3. application partition is deposited all application system files;
4. the user data subregion is deposited all user files.
The operational mode of tradition embedded system:
1. guidance system starts kernel;
2. on storage medium, set up the root partitions of file;
3. hang over user's application system subregion;
4. start user's service;
5. system normally moves.
The storage mode of the device operating file of traditional embedded system is to store in the mode of file, and various file storage are extracted in the time of operation in each file area in order.Though do so more convenient, very unfavorable for the upgrading of the operating file of these devices.The combination of file inside has determined the fixed mode of file, if upgrading needs to change whole file, yet the various program files of embedded system usually all the amount of being type cut and form, change the demand that whole file must take into full account hardware, this is very unfavorable for frequent upgrading.Yet the network equipment is upgrading often, therefore uses the upgrade problem of the network equipment of embedded system outstanding especially.
The employed hardware of present embodiment is that embodiment one is described, comprising: mainboard, central processing unit, random asccess memory, hard disk, WAN, LAN interface, USB interface, single-chip microcomputer, LCD MODULE, system's storage card.The basic ideas of present embodiment are: the storage of the device operating file of multifunctional network application equipment separates fully with running space, and is independent separately.The device operating file in except that the most basic operating file, all and subscriber-related operating file all carry out modularization to be handled, and according to the requirements definition and the Sign module of " application service module rule ", be stored on the storage medium as memory space with modular structure, these modules are referred to as " application service module ".Storage medium can be common hard disk or special-purpose system's storage card (DOM/CF card), and what present embodiment adopted is the DOM card.When multifunctional network application equipment starts each file and module are taken out from memory space, put into running space.The device operating file guides startup in running space, extract various user programs and data and move in running space.Running space is located in the random asccess memory, in the just common described internal memory.When device needs upgrading, only need to download new application service module in real time, in the original device operating file, upgrade the application corresponding service module and get final product according to " application service module rule " defined sign rule.This is modular benefit, and upgrade-system is simple, convenient.The memory moduleization of file is the key of present embodiment, has only file moduleization, and making has tangible boundary line that the part that need upgrade and not need to upgrade is separated between each block, selects more convenient in upgrading.The storage organization of system as shown in Figure 5, the storage organization and the operational mode of system are as follows:
Storage organization:
1. boot partition, storage system kernel and guidance system;
2. data partition is deposited all application systems, application service module.
The data partition structure:
Data partition has only a data catalogue, and all contents all are module in the data directory.Module is according to specific sign definition and storage, and system distinguishes according to ad hoc rules and loads different modules.
" application service module rule " is the rule of definition and signage applications service module, and this rule can determine arbitrarily that what present embodiment adopted is following rule:
Data partition has only a data catalogue, and all contents all are application service module in the data directory.
If module name starts with N, be inaction module, do not load, other are active module.
S000 is conventional module to S499, the unconditional loading:
Module with the S0 beginning is the infrastructure service module, is the initial data of all infrastructure services, does not comprise self-defining data, configuration file etc.;
Module with the S1 beginning is the infrastructure service companion module, is the self-defining data that can satisfy the demands when stating infrastructure service in the use, configuration file etc.;
Be the expansion service module that system provides when dispatching from the factory with the module of S2 beginning, similar with S0;
Be the expansion service companion module that system provides when dispatching from the factory with the module of S3 beginning, similar with S1;
S400, S499 are standby number of conventional module.
S500 is big data module to S999, only has just loading under the situation of hard disk:
Module with the S5 beginning is the high-level service module, is the initial data of all high-level service, does not comprise self-defining data, configuration file;
Module with the S6 beginning is a high-level service module companion module, is the self-defining data that can satisfy the demands when stating high-level service in the use, configuration file;
Be the senior expansion service module that system provides when dispatching from the factory with the module of S7 beginning, similar with S5;
Be the senior expansion service companion module that system provides when dispatching from the factory with the module of S8 beginning, similar with S6;
S900, S999 are standby number of big data module.
The online upgrading process of present embodiment as shown in Figure 6, comprises three big steps: verify/obtain, calculate/download, upgrade:
1. upgrade-system connects upgrade server upgrade service port;
2. server authentication upgrade-system legitimacy;
3. upgrade-system obtains data message to be upgraded;
4. upgrade-system is made comparisons upgrade data information and this machine data, obtains the upgrading tabulation;
5. upgrade-system download and upgrade module;
6. carry system storage card;
7. update system module;
8. uninstalling system storage card, upgrading is finished.
Wherein, 1-3 upgrades and is upgraded both sides and confirm its upgrading legitimacy, illegal invasion and disabled user mutually for verifying/obtaining.
4-5 is calculating/download, upgrades and is upgraded both sides and exchanges version information, determines the quantity of download module and downloads.
6-8 is a renewal process, the module of downloading is write in the interim memory space of system's storage card of loading, revises old module numbering title, revises newly downloaded module numbering title, replaces original module, and the uninstalling system storage card is finished upgrading.