1. Introduction
To provide seamless global three-dimensional (3D) coverage as well as to ensure the continuity of various services, the 6th generation mobile communication (6G) will integrate various terrestrial and non-terrestrial networks. There is a broad consensus that building a space-air-ground integrated network (SAGIN) will be a fundamental task of 6G [
1]. SAGIN will strongly contribute to the rapid development of Internet of Things (IoT). Future IoT applications will have larger data volumes and more traffic types, which require more computing power, more storage capacity, and larger transmission bandwidth [
2]. As a result, these innovative IoT applications have stringent requirements for storage (e.g., distributed storage), communication (e.g., higher transmission rates), and computation (e.g., real-time data analysis). In addition, with the maturity of artificial intelligence (AI) technology, intelligence is bound to be the evolutionary direction of IoT [
1,
2,
3].
The extreme pursuit for 6G performance and the stringent requirements of diverse applications are the two main drivers for efficient resource management in IoT. As more advanced computer technologies such as cloud computing, edge computing, and AI increasingly converge with communication networks, substantial computing power and storage capabilities are being introduced into communication networks. 6G will be the first truly converged Internet and Communications Technology (ICT) system. This means that communication resources and computer resources are equally important in 6G, and need to be managed in a unified manner. In addition, other resources, such as energy, should also be included in the unified resource management.
Federated Learning (FL), as an emerging distributed machine learning (ML) technology, has been introduced into the study of network resource management [
4,
5,
6]. Unlike the traditional centralized mechanism, in FL, the local model computation is performed at the node that generates the data and only the updated model parameters are uploaded. These local model parameters are aggregated in the FL server for generating the global model [
7,
8]. However, all IoT nodes involved in FL training should be trustworthy. Otherwise, it will seriously affect the reliability and validity of the aggregated global model. IoT nodes may be deployed in harsh or remote areas. Coupled with the fact that the IoT topology often changes dynamically, the network often has difficulty with identifying the inclusion of malicious nodes [
9]. According to the “2020 IoT Threat Report” published by PaloAltoNetworks’ security team Unit 42, 57% of IoT devices are vulnerable to medium- or high-severity attacks [
10]. Therefore, it is crucial to identify the malicious nodes to avoid the bad effects on FL.
Blockchain is a distributed database technology for storing transaction records. It uses some kind of consensus algorithm to reach a consensus among different nodes. It also enables non-repudiation among blocks so that none of the nodes can deny their actions [
11]. IoT nodes can be deployed in blockchains. A safe and reliable service guarantee for the model parameters exchange can then be provided. In addition, IoT companies are exploring the applications of “IoT + blockchains”. In 2020, Cat.1 blockchain module-L610 was first launched in China, which is the world’s leading developed based on the IoT chips platform and can be loaded into IoT devices. Future IoT devices that integrate the next-generation IoT modules and blockchain modules will have more powerful capabilities [
12].
In recent years, using FL for wireless network performance optimization and using blockchain to improve privacy protection in IoT have become two research hotspots. Refs. [
4,
13,
14] conducted a comprehensive survey on the application of FL techniques in wireless networks and analyzed various issues, challenges, and research directions. However, they did not investigate specific FL algorithms. In [
15], FL was used to solve the joint power and radio resource allocation problem for ultra-reliable and low-latency communication in vehicular networks. However, the reliability of FL training and transmission was not considered in [
15]. The authors in [
16] studied specific scheduling strategies and analyzed the impact of transmission errors on FL performance, but they did not perform FL participant selection to optimize the performance of the resource allocation algorithm. In most FL studies, the cloud servers in the core network are used as FL servers, while the FL local nodes are at the edge of the network. With the advent of mobile edge computing and the enhancement of terminal capabilities, FL migrates to the network edge and terminals [
6,
13,
17]. A client-edge-cloud hierarchical FL framework was proposed in [
17]. A collaborative FL (CFL) mechanism was proposed in [
6], which enables the edge devices to implement FL when they cannot communicate with the FL server for some reasons. Although FL is distributed, its central controller can pose security issues. Blockchain was applied to improve the security and non-repudiation of the FL mechanism in [
18,
19,
20,
21,
22,
23]. IEEE published the guide “an Architectural Framework for Blockchain-based Federated Machine Learning” in late 2021, which defined the types of blockchain-based federated machine learning, as well as application scenarios and other aspects from a high-level perspective [
18]. In [
19], malicious nodes were identified before participating in FL training. In [
20], a Blockchain Federated Learning architecture (BlockFL) was proposed, and the end-to-end latency model of BlockFL was analyzed. In [
21], a fine-grained FL mechanism with a blockchain-based reputation guarantee was proposed to achieve trustworthy FL training in edge networks. In [
22], a blockchain-assisted decentralized FL framework was proposed to solve the single point failure problem of FL servers. Although privacy and resource allocation issues were further investigated in [
22], no specific resource allocation algorithm was given. In the blockchain-based FL framework proposed in [
23], the FL server incentivized the participating nodes based on the accuracy of their uploaded model parameters to improve the accuracy of the classification problem. As the further development of joint FL and blockchain, a new concept, Swarm Learning (SL), was proposed in [
24]. Unlike FL, SL is a new distributed ML technique with no central controller. In [
24], SL was used to detect patients with severe diseases quickly and reliably. However, SL nodes are expected to be independent and homogeneous, i.e., they should preferably have similar capabilities. Therefore, SL may not be particularly suitable for heterogeneous IoT end devices.
We first analyze the key challenges of resource management in the future smart IoT, which motivates the research of this paper. Considering the heterogeneity of IoT end-device capabilities, we use FL for distributed intelligent management of IoT resources. In this approach, the central FL server aggregates the local model parameters from the end devices with different capabilities; then, a reliable global model can be quickly obtained and be shared among all FL nodes. To ensure the reliability of FL model parameters exchange, the FL nodes are deployed in the blockchain. In addition, we optimize FL training participant selection by performing detection on malicious nodes. The main contribution of this paper is an in-depth study of the FL-based resource management mechanism with blockchain trust assurance, and a specific resource management algorithm is given.
The rest is organized as follows:
Section 2 investigates the challenges of resource management in future smart IoT.
Section 3 analyzes the federated learning-based resource management mechanism with blockchain trust assurance.
Section 4 proposes a specific resource management algorithm.
Section 5 performs the simulation analysis.
Section 6 concludes this paper.
2. Challenges for Resource Management in the Future IoT Based on 6G SAGIN
In order to achieve efficient resource management in the future smart IoT based on 6G SAGIN, a clear analysis of the major challenges is the critical first step. The major challenges are discussed below from a high-level perspective.
2.1. Integrated Design Need for Communication and Computer Resources
ICT brings the need and possibility of joint management of communication and computer resources [
25]. Currently, industry is shifting from the division of network and computation to their synergy, and the concept of computation network is proposed [
26]. The future smart IoT needs to achieve collaborative scheduling and efficient sharing of communication and computer resources. It will improve the efficiency of the resources utilization and meet the performance requirements of different IoT applications.
The management of communication resources and computer resources should synergize with each other. On the one hand, with the abundant supply of computer resources and the support of powerful AI/ML algorithms, the 6G network will achieve rapid development. On the other hand, with the advancement of 6G, a large amount of computer resources will be fully and effectively utilized through the networked connection.
2.2. Representation of Multi-Dimensional and Multi-Domain Heterogeneous Resources
In future networks, the objects of communication resources management will have new characteristics, such as higher frequency bands, wider bandwidths, and more 3D beams. In the ICT network, various resources in computers will also be unified with communication resources, including CPUs, GPUs, and various storage resources (such as memory, external memory, etc.).
In addition, energy will be an important resource that needs to be managed in the future IoT. Although individual IoT devices consume less energy, the total energy consumption of massive IoT devices is staggering. The power supply and energy storage volume of heterogeneous IoT devices are also very different. For example, there are various power supply methods such as batteries, lithium batteries, and solar panels.
The management resources in different domains may also differ, and the system metrics they are more concerned with may also be different. The various resources in different domains need to be managed and scheduled in a unified manner, which firstly requires solving the problem of representing these heterogeneous resources. Under this premise, it can be considered in a balanced compromise.
2.3. Localized Learning and Distributed Interaction
Future IoT end devices, including various sensors, cameras, and user devices, have increasing computing power, storage capacity, and network connectivity. These devices will generate or store more data, which will be used to support more powerful and intelligent IoT applications. Locally processing these data is important to protect data privacy and accelerate application processing time. In addition, local processing is useful to greatly ease the transmission pressure. In addition, some applications may require localized learning, such as automated intelligent driving of vehicles. The intelligent control system needs to learn more about the environment around the moving vehicle, which is not very relevant to the environment elsewhere.
However, in general, localized learning is only an auxiliary mechanism for future IoT resource management. The future smart IoT should have large-scale distributed training and localized learning capabilities. Real-time distributed interactions are needed between local devices and controllers to exchange resource management information. Integrated management and unified scheduling mechanism can achieve optimal resource allocation.
2.4. Dynamic Change of Network Environment
In the future 6G SAGIN-based IoT, the network environment will be highly dynamic and change. This dynamic change is reflected in several aspects. First, different IoT devices have different dynamic characteristics. Some end-devices may be in fast motion, such as cars, logistics end-users, etc. Second, ground base stations are more densely deployed and more diverse, so users may encounter more frequent network handoff in the communication process. Third, the movement of communication satellites is very fast; a satellite typically serves users for only a few minutes, which can lead to more frequent beam switching. Fourth, low-flying Unmanned Aerial Vehicles (UAVs), whether as airborne base stations or as airborne IoT users, will bring dynamic changes in the network environment. In addition, the expansion of traditional terrestrial wireless channels into the air also enhances the dynamics of wireless communication links, while the time-varying characteristics of the channels shift to time–space variations.
2.5. Trustworthiness Issues of IoT Nodes
The lack of effective data security protection has been a major issue for IoT technologies. For example, existing transportation and shipping management systems are suffering from serious security and privacy issues [
27]. In traditional IoT, the centralized security authentication mechanism does not handle well the security and privacy of IoT data that are distributed everywhere. Each IoT node specifying its precise location information is an important prerequisite for a trustworthy IoT. However, it is difficult to find the precise location of these IoT nodes because they are often densely deployed deep in industrial buildings, or in harsh and remote areas, or due to energy constraints. Intruders may also attack IoT nodes and bring about trust issues among IoT nodes by broadcasting wrong information. For trusted IoT, these nodes then become malicious nodes, and they can seriously affect the network performance.
The trustworthiness issue of IoT also includes non-repudiation between service providers and IoT nodes. If a node provides malicious or useless (non-compliant) services to other nodes, it should be able to be identified and not be able to repudiate its actions [
9].
4. Proposed FL-Based Resource Management with Blockchain Trust Assurance Algorithm
Currently, most IoT applications are deployed in cloud servers in core networks. As MECs are deployed on a large scale and more and more small- and medium-volume IoT applications are launched, more IoT applications will be deployed in MEC servers at network edges. Of course, this does not preclude some large IoT applications from still being deployed in the core cloud servers. In this paper, we focus on the case of IoT applications deployed in MEC servers. FL servers and FL local devices share the same training models, and FL servers are deployed in MEC servers. Different IoT applications achieve distributed collaborative resource management by invoking FL service mechanisms.
Suppose that there are N local devices involved in the FL training and there are K classes of different resources to be managed. denotes the size of the jth class resource of local device i, .
The normalized representation of the resources of
is
The total resources of participant local device
i are denoted as
is a weighted logical resource representation.
denotes the weight of the
jth class resource in the participant selection, which satisfies
To prevent the impact of malicious nodes on the FL training, this paper identifies the malicious nodes and removes them from the network before federated training. In this paper, malicious nodes are detected using support vector machines (SVM), which is a supervised learning technique that enables binary classification of data [
9,
23]. SVM finds a hyperplane (i.e., decision boundary) in
N-dimensional space, and each
N-dimensional data point is divided on both sides of the hyperplane, thus classifying these data points into two classes.
In this paper, the goal of SVM is to compute the binary classification of different IoT nodes (including end devices, IoT gateways, IoT servers, etc.), as shown in Equation (
4):
where
X denotes the input data vector consisting of
K classes of different resources, and
y is the binary classification value:
is the local data input of the local model FL training algorithm performed by local device i. Its size depends on the specific FL training task.
The decision boundary of the local nodes is given by Equation (
6):
where
is the weight vector, and
is the threshold value, which is geometrically expressed as the intercept of this hyperplane. Hence,
y in Equation (
4) can be determined from Equation (
7):
The local node trustworthiness trust is defined as the probability of successful interaction of the local node with the FL server and is calculated by Equation (
8):
where
is the total number of interactions between a local node and the FL server over a period of time, and
is the number of successful interactions. If
or
, the local node
i is considered as a malicious or untrustworthy node.
Since a nonlinear dynamic process requires a series of complex algorithms to be implemented [
31], the linear regression FL algorithm is used in this paper in order to clearly analyze the performance of the proposed algorithm [
32]. Define
as the global model,
as the local model, and
as the local model parameters.
Assume that the output of the FL algorithm is
in local device
i. The input and output of the FL algorithm follow Equation (
9):
where
n follows Gaussian distribution
.
In this paper, the problem of local FL training is to find an optimal model parameter
that minimizes its loss function. This problem is given by Equation (
10):
The constraint in Equation (
10) states that all local FL models and the global FL model (
) share the same model parameters at the end of the FL training algorithm.
For different FL training tasks, different loss functions can be defined. For the FL linear regression FL algorithm in this paper, the loss function in Equation (
10) can be simply defined as
In Equation (
11),
is the predicted output. Thus, the loss function is defined as the square of the prediction error. This indicates that the value of the loss function will increase sharply as the prediction error increases. Therefore, using the loss function as the performance indicator of the FL algorithm can clearly reflect the accuracy of the FL algorithm.
The flowchart of the proposed FL-based resource management with the blockchain trust assurance algorithm is given in
Figure 4. The detailed steps are as follows.
Step 1. The application initiates the resource request.
The IoT application deployed in the MEC server invokes the FL server to initiate a resource request to the connected local IoT devices through the edge network. These local devices will eventually take on the role of task execution.
Step 2. Resource reporting and participant selection for FL training.
The local devices that have received resource requests and agree to participate in FL training report their communication bandwidth, computing power, available storage size, data volume, and their energy status to the FL server.
The FL server normalizes the various resources for each device and then aggregates them in a weighted manner to obtain the total resource R(i) of the device. The decision boundary is calculated using the SVM mechanism, and the classification is obtained by Equation (
7). The trustworthiness of the local node is calculated by Equation (
8). If the FL server judges that the node is a malicious node or an untrustworthy node, the node will not be selected to participate in the FL training. This selection mechanism is simple and fast, and can reflect the degree of influence of different types of resources on the selection of FL participants by adjusting the size of the weights. Moreover, by detecting and eliminating untrustworthy nodes from participating in FL model training, the long FL model training time can be avoided and the accuracy of the global model can be guaranteed.
Step 3. FL local model training update and the updated parameters are uploaded to the blockchain.
The local devices that have received confirmation of the FL training participant selection start the FL local training update. The first-round local model update is based on the local dataset, and subsequent updates will also be based on the global model updated parameters sent by the FL server. The updated model parameters are uploaded to the blockchain after the local model training is completed, and then the FL server obtains the updated local model parameters from the blockchain.
Step 4. FL server performs a global model update, and the updated parameters are uploaded to the blockchain.
After the FL server obtains the local model updated parameters of all participant devices, it performs a global model update using the received trained local model parameters as well as application-related data. This is a synchronous update method. The global model updated parameters are uploaded to the blockchain, and then the local nodes obtain the global model updated parameters from the blockchain.
Step 5. Repeat step 3 and step 4 until the training accuracy and reliability of the global model in the FL server meet the requirements.
Step 6. The final global model is published, and the application tasks are executed.
The FL server uploads the trained final global model parameters to the blockchain and downloads it to all local devices that can communicate directly with it, not just the devices selected for participating in local model training. The local devices that cannot communicate directly with the FL server can then obtain the global model parameters from other local devices via device-to-device (D2D) method.
Note: Usually, there are two approaches for FL global model update: synchronous and asynchronous. For the case with a large number of heterogeneous IoT devices, the asynchronous global model update has high overhead and slow convergence, and the trained model may also not be accurate enough. For the synchronous approach, the FL server updates the global model only after all of the local parameters are obtained. Although the update period is longer, it is possible to converge to a stable and accurate model with fewer update iterations. In addition, it is crucial to ensure the FL training progress, i.e., all the devices involved in the FL local models training should have roughly equal time to train the local models and upload the model parameters to avoid the straggler effect as much as possible. The FL server in step 3 can ensure both that all local model update parameters are received within a guaranteed time and that there are enough local training participants to ensure the accuracy of the trained global model.